compnerd added inline comments.
================
Comment at: src/Registers.hpp:1497
@@ -1479,3 +1496,3 @@
_LIBUNWIND_ABORT("unsupported arm register");
}
----------------
rmaprath wrote:
> compnerd wrote:
> > Early returns would be nicer imo.
> Not sure if I follow, did you mean to check the bounds of `regNum` the first
> thing and `_LIBUNWIND_ABORT` sooner than later? Might convolute the code
> given the conditional on `__ARM_WMMX` and I'm not sure what benefit it
> brings? Or perhaps I misunderstood you?
>
> I'll commit the current patch as it is for the moment and then do a clean-up
> (once I understand what you mean).
>
> Thanks.
Oh, that was meant, as, we can write the code a slight bit nicer, which is
beyond the scope of your change. If you don't mind doing a bit more clean up
-- a follow up patch to improve this would be appreciated!
Basically, we have a number of if/else if cases with a unreachable. We should
replace this with a series of
if (<condition>) {
<operation>
return;
}
Repository:
rL LLVM
http://reviews.llvm.org/D21991
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits