[PATCH] code refactoring on ARMTargetInfo class

Alexandros Lamprineas alexandros.lamprineas at arm.com
Wed Jul 1 08:47:45 PDT 2015


REPOSITORY
  rL LLVM

================
Comment at: lib/Basic/Targets.cpp:4338
@@ +4337,3 @@
+    ArchProfile = llvm::ARMTargetParser::parseArchProfile(ArchName);
+    ArchVersion = llvm::ARMTargetParser::parseArchVersion(ArchName);
+ 
----------------
rengolin wrote:
> labrinea wrote:
> > rengolin wrote:
> > > You should also set IsThumb and ShouldUseInlineAtomic
> > Setting IsThumb in setCPU causes regressions. It doesn't make sense to me but setCPU changes the ISA from thumb to arm.
> Right, this is a major bug and needs to be addressed. You shouldn't mix TargetParser changes with bug fixes, but would be good to add a FIXME comment and open a bug in bugzilla to describe the problem.
> 
> What about ShouldUseInlineAtomic?
In the current implementation ShouldUseInlineAtomic is checking llvm::triple which is set in the constructor. Apparently, setCPU checks MaxAtomicInlineWidth (which is also set in the constructor depending on the value of ShouldUseInlineAtomic), thus takes into account the ISA from llvm::triple.

http://reviews.llvm.org/D10839

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the cfe-commits mailing list