From ece7217f70c41a2b983c937ce292540dc33b0b40 Mon Sep 17 00:00:00 2001 From: Saleem Abdulrasool Date: Thu, 3 Jul 2014 02:43:20 +0000 Subject: [PATCH] ARM: rename ARM builtins to use __builtin_arm prefix This corrects SVN r212196's naming change to use the proper prefix of `__builtin_arm_` instead of `__builtin_`. Thanks to Yi Kong for pointing out the incorrect naming! llvm-svn: 212253 --- clang/include/clang/Basic/BuiltinsARM.def | 10 +++++----- clang/lib/CodeGen/CGBuiltin.cpp | 10 +++++----- clang/test/CodeGen/builtins-arm.c | 10 +++++----- 3 files changed, 15 insertions(+), 15 deletions(-) diff --git a/clang/include/clang/Basic/BuiltinsARM.def b/clang/include/clang/Basic/BuiltinsARM.def index 2197f59..7f32e87 100644 --- a/clang/include/clang/Basic/BuiltinsARM.def +++ b/clang/include/clang/Basic/BuiltinsARM.def @@ -68,11 +68,11 @@ BUILTIN(__builtin_arm_crc32d, "UiUiLLUi", "nc") BUILTIN(__builtin_arm_crc32cd, "UiUiLLUi", "nc") // HINT -BUILTIN(__builtin_yield, "v", "") -BUILTIN(__builtin_wfe, "v", "") -BUILTIN(__builtin_wfi, "v", "") -BUILTIN(__builtin_sev, "v", "") -BUILTIN(__builtin_sevl, "v", "") +BUILTIN(__builtin_arm_yield, "v", "") +BUILTIN(__builtin_arm_wfe, "v", "") +BUILTIN(__builtin_arm_wfi, "v", "") +BUILTIN(__builtin_arm_sev, "v", "") +BUILTIN(__builtin_arm_sevl, "v", "") // Data barrier BUILTIN(__builtin_arm_dmb, "vUi", "nc") diff --git a/clang/lib/CodeGen/CGBuiltin.cpp b/clang/lib/CodeGen/CGBuiltin.cpp index ce53f0a..e70ade3 100644 --- a/clang/lib/CodeGen/CGBuiltin.cpp +++ b/clang/lib/CodeGen/CGBuiltin.cpp @@ -3033,23 +3033,23 @@ Value *CodeGenFunction::EmitARMBuiltinExpr(unsigned BuiltinID, unsigned HintID = static_cast(-1); switch (BuiltinID) { default: break; - case ARM::BI__builtin_yield: + case ARM::BI__builtin_arm_yield: case ARM::BI__yield: HintID = 1; break; - case ARM::BI__builtin_wfe: + case ARM::BI__builtin_arm_wfe: case ARM::BI__wfe: HintID = 2; break; - case ARM::BI__builtin_wfi: + case ARM::BI__builtin_arm_wfi: case ARM::BI__wfi: HintID = 3; break; - case ARM::BI__builtin_sev: + case ARM::BI__builtin_arm_sev: case ARM::BI__sev: HintID = 4; break; - case ARM::BI__builtin_sevl: + case ARM::BI__builtin_arm_sevl: case ARM::BI__sevl: HintID = 5; break; diff --git a/clang/test/CodeGen/builtins-arm.c b/clang/test/CodeGen/builtins-arm.c index 1d22bd5..7b72072 100644 --- a/clang/test/CodeGen/builtins-arm.c +++ b/clang/test/CodeGen/builtins-arm.c @@ -20,31 +20,31 @@ void test_eh_return_data_regno() } void yield() { - __builtin_yield(); + __builtin_arm_yield(); } // CHECK: call {{.*}} @llvm.arm.hint(i32 1) void wfe() { - __builtin_wfe(); + __builtin_arm_wfe(); } // CHECK: call {{.*}} @llvm.arm.hint(i32 2) void wfi() { - __builtin_wfi(); + __builtin_arm_wfi(); } // CHECK: call {{.*}} @llvm.arm.hint(i32 3) void sev() { - __builtin_sev(); + __builtin_arm_sev(); } // CHECK: call {{.*}} @llvm.arm.hint(i32 4) void sevl() { - __builtin_sevl(); + __builtin_arm_sevl(); } // CHECK: call {{.*}} @llvm.arm.hint(i32 5) -- 2.7.4