[PATCH] D12681: Calling conventions for HHVM
Sanjoy Das via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 7 16:09:29 PDT 2015
sanjoy added a comment.
By no means a "proper" review, but two things I noticed on a quick scan:
================
Comment at: include/llvm/Support/MathExtras.h:619
@@ -608,3 +618,3 @@
/// \endcode
-inline uint64_t RoundUpToAlignment(uint64_t Value, uint64_t Align) {
- return (Value + Align - 1) / Align * Align;
+inline uint64_t RoundUpToAlignment(uint64_t Value, uint64_t Align,
+ uint64_t Skew = 0) {
----------------
Should this have a test in `Support/MathExtrasTest.cpp`?
================
Comment at: lib/CodeGen/PrologEpilogInserter.cpp:570
@@ +569,3 @@
+ unsigned Skew = 0;
+ if (LLVM_UNLIKELY(Fn.getFunction()->getCallingConv() == CallingConv::HHVM)) {
+ Skew = 8;
----------------
I'd skip the braces for the single line body, like elsewhere in LLVM.
http://reviews.llvm.org/D12681
More information about the llvm-commits
mailing list