From 2cb8c10342ee5d040725abb1166feb92a64c7df6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?D=C3=A1vid=20Bolvansk=C3=BD?= Date: Thu, 8 Apr 2021 17:28:57 +0200 Subject: Revert "Reduce the number of attributes attached to each function" This reverts commit 053dc95839b3b8a36db46f8c419e36e632e989cd. It causes perf regressions - see discussion in D97116. --- clang/lib/CodeGen/CodeGenFunction.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'clang/lib/CodeGen/CodeGenFunction.cpp') diff --git a/clang/lib/CodeGen/CodeGenFunction.cpp b/clang/lib/CodeGen/CodeGenFunction.cpp index 600312e..5ff969d 100644 --- a/clang/lib/CodeGen/CodeGenFunction.cpp +++ b/clang/lib/CodeGen/CodeGenFunction.cpp @@ -493,8 +493,7 @@ void CodeGenFunction::FinishFunction(SourceLocation EndLoc) { // 4. Width of vector arguments and return types for this function. // 5. Width of vector aguments and return types for functions called by this // function. - if (LargestVectorWidth) - CurFn->addFnAttr("min-legal-vector-width", llvm::utostr(LargestVectorWidth)); + CurFn->addFnAttr("min-legal-vector-width", llvm::utostr(LargestVectorWidth)); // Add vscale attribute if appropriate. if (getLangOpts().ArmSveVectorBits) { -- cgit v1.1