You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
chromium/chromium-92-v8-constexpr.patch

18 lines
762 B

GCC: make VRegister::from_code() constexpr on aarch64
LiftoffRegister::gp() and LiftoffRegister::fp() are constexpr.
Therefore, VRegister::from_code() needs to be constexpr as well.
diff --git a/v8/src/codegen/arm64/register-arm64.h b/v8/src/codegen/arm64/register-arm64.h
index 1150daf..21007a5 100644
--- a/v8/src/codegen/arm64/register-arm64.h
+++ b/v8/src/codegen/arm64/register-arm64.h
@@ -413,7 +413,7 @@ class VRegister : public CPURegister {
static constexpr int kMaxNumRegisters = kNumberOfVRegisters;
STATIC_ASSERT(kMaxNumRegisters == kDoubleAfterLast);
- static VRegister from_code(int code) {
+ static constexpr VRegister from_code(int code) {
// Always return a D register.
return VRegister::Create(code, kDRegSizeInBits);
}