[PATCH] D54661: [WebAssembly] Don't override default implementation of isOffsetFoldingLegal. NFC.
Sam Clegg via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 11 15:59:23 PDT 2019
sbc100 updated this revision to Diff 190174.
sbc100 edited the summary of this revision.
sbc100 added a comment.
Herald added a subscriber: jdoerfert.
Herald added a project: LLVM.
- rebase
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D54661/new/
https://reviews.llvm.org/D54661
Files:
lib/Target/TargetMachine.cpp
lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
lib/Target/WebAssembly/WebAssemblyISelLowering.h
Index: lib/Target/WebAssembly/WebAssemblyISelLowering.h
===================================================================
--- lib/Target/WebAssembly/WebAssemblyISelLowering.h
+++ lib/Target/WebAssembly/WebAssemblyISelLowering.h
@@ -46,7 +46,6 @@
AtomicExpansionKind shouldExpandAtomicRMWInIR(AtomicRMWInst *) const override;
FastISel *createFastISel(FunctionLoweringInfo &FuncInfo,
const TargetLibraryInfo *LibInfo) const override;
- bool isOffsetFoldingLegal(const GlobalAddressSDNode *GA) const override;
MVT getScalarShiftAmountTy(const DataLayout &DL, EVT) const override;
MachineBasicBlock *
EmitInstrWithCustomInserter(MachineInstr &MI,
Index: lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
===================================================================
--- lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
+++ lib/Target/WebAssembly/WebAssemblyISelLowering.cpp
@@ -294,12 +294,6 @@
return WebAssembly::createFastISel(FuncInfo, LibInfo);
}
-bool WebAssemblyTargetLowering::isOffsetFoldingLegal(
- const GlobalAddressSDNode * /*GA*/) const {
- // All offsets can be folded.
- return true;
-}
-
MVT WebAssemblyTargetLowering::getScalarShiftAmountTy(const DataLayout & /*DL*/,
EVT VT) const {
unsigned BitWidth = NextPowerOf2(VT.getSizeInBits() - 1);
Index: lib/Target/TargetMachine.cpp
===================================================================
--- lib/Target/TargetMachine.cpp
+++ lib/Target/TargetMachine.cpp
@@ -161,7 +161,7 @@
if (GV && !GV->hasDefaultVisibility())
return true;
- if (TT.isOSBinFormatMachO()) {
+ if (TT.isOSBinFormatMachO() || TT.isOSBinFormatWasm()) {
if (RM == Reloc::Static)
return true;
return GV && GV->isStrongDefinitionForLinker();
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D54661.190174.patch
Type: text/x-patch
Size: 1830 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190311/8ff90e42/attachment.bin>
More information about the llvm-commits
mailing list