<p dir="ltr">Looks more like left over of a bad refactoring than an intentional feature. I can't see any reason to keep that code... LGTM. </p>
<p dir="ltr">Cheers, <br>
Renato </p>
<div class="gmail_quote">On 12 Jun 2013 01:33, "Rui Ueyama" <<a href="mailto:ruiu@google.com">ruiu@google.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi Bigcheese,<br>
<br>
Architecture specific code should reside in architecture specific directory,<br>
not in Atom. Looks like there are no efforts being made at this moment to<br>
support ARM, so let's remove it for now.<br>
<br>
<a href="http://llvm-reviews.chandlerc.com/D959" target="_blank">http://llvm-reviews.chandlerc.com/D959</a><br>
<br>
Files:<br>
include/lld/Core/DefinedAtom.h<br>
include/lld/ReaderWriter/Simple.h<br>
lib/ReaderWriter/CoreTargetInfo.cpp<br>
lib/ReaderWriter/ELF/Atoms.h<br>
lib/ReaderWriter/Native/ReaderNative.cpp<br>
lib/ReaderWriter/Native/WriterNative.cpp<br>
lib/ReaderWriter/PECOFF/ReaderCOFF.cpp<br>
lib/ReaderWriter/YAML/ReaderWriterYAML.cpp<br>
<br>
Index: include/lld/Core/DefinedAtom.h<br>
===================================================================<br>
--- include/lld/Core/DefinedAtom.h<br>
+++ include/lld/Core/DefinedAtom.h<br>
@@ -253,11 +253,6 @@<br>
/// is R__.<br>
virtual ContentPermissions permissions() const;<br>
<br>
- /// \brief only applicable to ARM code. Tells the linker if the code uses<br>
- /// thumb or arm instructions. The linker needs to know this to set the low<br>
- /// bit of pointers to thumb functions.<br>
- virtual bool isThumb() const = 0;<br>
-<br>
/// \brief means this is a zero size atom that exists to provide an alternate<br>
/// name for another atom. Alias atoms must have a special Reference to the<br>
/// atom they alias which the layout engine recognizes and forces the alias<br>
Index: include/lld/ReaderWriter/Simple.h<br>
===================================================================<br>
--- include/lld/ReaderWriter/Simple.h<br>
+++ include/lld/ReaderWriter/Simple.h<br>
@@ -128,8 +128,6 @@<br>
return DefinedAtom::deadStripNormal;<br>
}<br>
<br>
- virtual bool isThumb() const { return false; }<br>
-<br>
virtual bool isAlias() const { return false; }<br>
<br>
virtual DefinedAtom::reference_iterator begin() const {<br>
Index: lib/ReaderWriter/CoreTargetInfo.cpp<br>
===================================================================<br>
--- lib/ReaderWriter/CoreTargetInfo.cpp<br>
+++ lib/ReaderWriter/CoreTargetInfo.cpp<br>
@@ -84,10 +84,6 @@<br>
return DefinedAtom::permR_X;<br>
}<br>
<br>
- virtual bool isThumb() const {<br>
- return false;<br>
- }<br>
-<br>
virtual bool isAlias() const {<br>
return false;<br>
}<br>
@@ -180,10 +176,6 @@<br>
return DefinedAtom::permRW_;<br>
}<br>
<br>
- virtual bool isThumb() const {<br>
- return false;<br>
- }<br>
-<br>
virtual bool isAlias() const {<br>
return false;<br>
}<br>
Index: lib/ReaderWriter/ELF/Atoms.h<br>
===================================================================<br>
--- lib/ReaderWriter/ELF/Atoms.h<br>
+++ lib/ReaderWriter/ELF/Atoms.h<br>
@@ -434,12 +434,6 @@<br>
}<br>
}<br>
<br>
- // Many non ARM architectures use ELF file format This not really a place to<br>
- // put a architecture specific method in an atom. A better approach is needed.<br>
- virtual bool isThumb() const {<br>
- return false;<br>
- }<br>
-<br>
// FIXME: Not Sure if ELF supports alias atoms. Find out more.<br>
virtual bool isAlias() const {<br>
return false;<br>
Index: lib/ReaderWriter/Native/ReaderNative.cpp<br>
===================================================================<br>
--- lib/ReaderWriter/Native/ReaderNative.cpp<br>
+++ lib/ReaderWriter/Native/ReaderNative.cpp<br>
@@ -94,10 +94,6 @@<br>
return (DefinedAtom::ContentPermissions)(attributes().permissions);<br>
}<br>
<br>
- virtual bool isThumb() const {<br>
- return false; //(attributes().thumb != 0);<br>
- }<br>
-<br>
virtual bool isAlias() const {<br>
return (attributes().alias != 0);<br>
}<br>
Index: lib/ReaderWriter/Native/WriterNative.cpp<br>
===================================================================<br>
--- lib/ReaderWriter/Native/WriterNative.cpp<br>
+++ lib/ReaderWriter/Native/WriterNative.cpp<br>
@@ -441,7 +441,6 @@<br>
= atom.sectionChoice() << 4 | atom.sectionPosition();<br>
attrs.deadStrip = atom.deadStrip();<br>
attrs.permissions = atom.permissions();<br>
- //attrs.thumb = atom.isThumb();<br>
attrs.alias = atom.isAlias();<br>
}<br>
<br>
Index: lib/ReaderWriter/PECOFF/ReaderCOFF.cpp<br>
===================================================================<br>
--- lib/ReaderWriter/PECOFF/ReaderCOFF.cpp<br>
+++ lib/ReaderWriter/PECOFF/ReaderCOFF.cpp<br>
@@ -176,10 +176,6 @@<br>
return perm___;<br>
}<br>
<br>
- virtual bool isThumb() const {<br>
- return false;<br>
- }<br>
-<br>
virtual bool isAlias() const {<br>
return false;<br>
}<br>
Index: lib/ReaderWriter/YAML/ReaderWriterYAML.cpp<br>
===================================================================<br>
--- lib/ReaderWriter/YAML/ReaderWriterYAML.cpp<br>
+++ lib/ReaderWriter/YAML/ReaderWriterYAML.cpp<br>
@@ -933,7 +933,6 @@<br>
virtual SectionPosition sectionPosition() const{return _sectionPosition;}<br>
virtual DeadStripKind deadStrip() const { return _deadStrip; }<br>
virtual ContentPermissions permissions() const { return _permissions; }<br>
- virtual bool isThumb() const { return false; }<br>
virtual bool isAlias() const { return false; }<br>
ArrayRef<uint8_t> rawContent() const {<br>
return ArrayRef<uint8_t>(<br>
<br>_______________________________________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@cs.uiuc.edu">llvm-commits@cs.uiuc.edu</a><br>
<a href="http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits" target="_blank">http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits</a><br>
<br></blockquote></div>