Skip to content

Commit eb02b6a

Browse files
committed
Merge branch 'main' into pauth-lld
2 parents 05cf361 + 6288f36 commit eb02b6a

File tree

77 files changed

+3498
-1850
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

77 files changed

+3498
-1850
lines changed

clang/include/clang/Serialization/ASTBitCodes.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ namespace serialization {
4141
/// Version 4 of AST files also requires that the version control branch and
4242
/// revision match exactly, since there is no backward compatibility of
4343
/// AST files at this time.
44-
const unsigned VERSION_MAJOR = 29;
44+
const unsigned VERSION_MAJOR = 30;
4545

4646
/// AST file minor version number supported by this version of
4747
/// Clang.

clang/include/clang/Serialization/ASTWriter.h

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -542,6 +542,7 @@ class ASTWriter : public ASTDeserializationListener,
542542
void WriteReferencedSelectorsPool(Sema &SemaRef);
543543
void WriteIdentifierTable(Preprocessor &PP, IdentifierResolver &IdResolver,
544544
bool IsModule);
545+
void WriteDeclAndTypes(ASTContext &Context);
545546
void WriteDeclUpdatesBlocks(RecordDataImpl &OffsetsRecord);
546547
void WriteDeclContextVisibleUpdate(const DeclContext *DC);
547548
void WriteFPPragmaOptions(const FPOptionsOverride &Opts);
@@ -846,7 +847,7 @@ class ASTWriter : public ASTDeserializationListener,
846847
/// AST and semantic-analysis consumer that generates a
847848
/// precompiled header from the parsed source code.
848849
class PCHGenerator : public SemaConsumer {
849-
const Preprocessor &PP;
850+
Preprocessor &PP;
850851
std::string OutputFile;
851852
std::string isysroot;
852853
Sema *SemaPtr;
@@ -867,11 +868,12 @@ class PCHGenerator : public SemaConsumer {
867868
DiagnosticsEngine &getDiagnostics() const {
868869
return SemaPtr->getDiagnostics();
869870
}
871+
Preprocessor &getPreprocessor() { return PP; }
870872

871873
virtual Module *getEmittingModule(ASTContext &Ctx);
872874

873875
public:
874-
PCHGenerator(const Preprocessor &PP, InMemoryModuleCache &ModuleCache,
876+
PCHGenerator(Preprocessor &PP, InMemoryModuleCache &ModuleCache,
875877
StringRef OutputFile, StringRef isysroot,
876878
std::shared_ptr<PCHBuffer> Buffer,
877879
ArrayRef<std::shared_ptr<ModuleFileExtension>> Extensions,
@@ -893,7 +895,7 @@ class ReducedBMIGenerator : public PCHGenerator {
893895
virtual Module *getEmittingModule(ASTContext &Ctx) override;
894896

895897
public:
896-
ReducedBMIGenerator(const Preprocessor &PP, InMemoryModuleCache &ModuleCache,
898+
ReducedBMIGenerator(Preprocessor &PP, InMemoryModuleCache &ModuleCache,
897899
StringRef OutputFile);
898900

899901
void HandleTranslationUnit(ASTContext &Ctx) override;

clang/lib/AST/DeclBase.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1852,9 +1852,9 @@ DeclContext::lookup(DeclarationName Name) const {
18521852

18531853
DeclContext::lookup_result
18541854
DeclContext::noload_lookup(DeclarationName Name) {
1855-
assert(getDeclKind() != Decl::LinkageSpec &&
1856-
getDeclKind() != Decl::Export &&
1857-
"should not perform lookups into transparent contexts");
1855+
// For transparent DeclContext, we should lookup in their enclosing context.
1856+
if (getDeclKind() == Decl::LinkageSpec || getDeclKind() == Decl::Export)
1857+
return getParent()->noload_lookup(Name);
18581858

18591859
DeclContext *PrimaryContext = getPrimaryContext();
18601860
if (PrimaryContext != this)

clang/lib/CodeGen/BackendUtil.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,8 +100,8 @@ using namespace llvm;
100100
namespace llvm {
101101
extern cl::opt<bool> PrintPipelinePasses;
102102

103-
cl::opt<bool> ClRemoveTraps("clang-remove-traps", cl::Optional,
104-
cl::desc("Insert remove-traps pass."));
103+
static cl::opt<bool> ClRemoveTraps("clang-remove-traps", cl::Optional,
104+
cl::desc("Insert remove-traps pass."));
105105

106106
// Experiment to move sanitizers earlier.
107107
static cl::opt<bool> ClSanitizeOnOptimizerEarlyEP(

clang/lib/Driver/ToolChains/MSVC.h

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,8 @@ class LLVM_LIBRARY_VISIBILITY MSVCToolChain : public ToolChain {
6161
/// formats, and to DWARF otherwise. Users can use -gcodeview and -gdwarf to
6262
/// override the default.
6363
llvm::codegenoptions::DebugInfoFormat getDefaultDebugFormat() const override {
64-
return getTriple().isOSBinFormatMachO()
65-
? llvm::codegenoptions::DIF_DWARF
66-
: llvm::codegenoptions::DIF_CodeView;
64+
return getTriple().isOSBinFormatCOFF() ? llvm::codegenoptions::DIF_CodeView
65+
: llvm::codegenoptions::DIF_DWARF;
6766
}
6867

6968
/// Set the debugger tuning to "default", since we're definitely not tuning

clang/lib/Frontend/PrecompiledPreamble.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -290,8 +290,7 @@ class PrecompilePreambleAction : public ASTFrontendAction {
290290

291291
class PrecompilePreambleConsumer : public PCHGenerator {
292292
public:
293-
PrecompilePreambleConsumer(PrecompilePreambleAction &Action,
294-
const Preprocessor &PP,
293+
PrecompilePreambleConsumer(PrecompilePreambleAction &Action, Preprocessor &PP,
295294
InMemoryModuleCache &ModuleCache,
296295
StringRef isysroot,
297296
std::shared_ptr<PCHBuffer> Buffer)

clang/lib/Sema/SemaStmtAttr.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -406,8 +406,8 @@ static void CheckForDuplicateLoopAttrs(Sema &S, ArrayRef<const Attr *> Attrs) {
406406
<< *FirstItr;
407407
S.Diag((*FirstItr)->getLocation(), diag::note_previous_attribute);
408408
}
409-
return;
410409
}
410+
return;
411411
}
412412

413413
static Attr *handleMSConstexprAttr(Sema &S, Stmt *St, const ParsedAttr &A,

clang/lib/Serialization/ASTReader.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6622,17 +6622,17 @@ void ASTReader::ReadPragmaDiagnosticMappings(DiagnosticsEngine &Diag) {
66226622
while (NumLocations--) {
66236623
assert(Idx < Record.size() &&
66246624
"Invalid data, missing pragma diagnostic states");
6625-
SourceLocation Loc = ReadSourceLocation(F, Record[Idx++]);
6626-
auto IDAndOffset = SourceMgr.getDecomposedLoc(Loc);
6627-
assert(IDAndOffset.first.isValid() && "invalid FileID for transition");
6628-
assert(IDAndOffset.second == 0 && "not a start location for a FileID");
6625+
FileID FID = ReadFileID(F, Record, Idx);
6626+
assert(FID.isValid() && "invalid FileID for transition");
6627+
// FIXME: Remove this once we don't need the side-effects.
6628+
(void)SourceMgr.getSLocEntryOrNull(FID);
66296629
unsigned Transitions = Record[Idx++];
66306630

66316631
// Note that we don't need to set up Parent/ParentOffset here, because
66326632
// we won't be changing the diagnostic state within imported FileIDs
66336633
// (other than perhaps appending to the main source file, which has no
66346634
// parent).
6635-
auto &F = Diag.DiagStatesByLoc.Files[IDAndOffset.first];
6635+
auto &F = Diag.DiagStatesByLoc.Files[FID];
66366636
F.StateTransitions.reserve(F.StateTransitions.size() + Transitions);
66376637
for (unsigned I = 0; I != Transitions; ++I) {
66386638
unsigned Offset = Record[Idx++];

clang/lib/Serialization/ASTWriter.cpp

Lines changed: 68 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -3131,9 +3131,7 @@ void ASTWriter::WritePragmaDiagnosticMappings(const DiagnosticsEngine &Diag,
31313131
continue;
31323132
++NumLocations;
31333133

3134-
SourceLocation Loc = Diag.SourceMgr->getComposedLoc(FileIDAndFile.first, 0);
3135-
assert(!Loc.isInvalid() && "start loc for valid FileID is invalid");
3136-
AddSourceLocation(Loc, Record);
3134+
AddFileID(FileIDAndFile.first, Record);
31373135

31383136
Record.push_back(FileIDAndFile.second.StateTransitions.size());
31393137
for (auto &StatePoint : FileIDAndFile.second.StateTransitions) {
@@ -5109,69 +5107,7 @@ ASTFileSignature ASTWriter::WriteASTCore(Sema &SemaRef, StringRef isysroot,
51095107
for (auto *D : SemaRef.DeclsToCheckForDeferredDiags)
51105108
DeclsToCheckForDeferredDiags.push_back(GetDeclRef(D));
51115109

5112-
{
5113-
auto Abv = std::make_shared<BitCodeAbbrev>();
5114-
Abv->Add(llvm::BitCodeAbbrevOp(UPDATE_VISIBLE));
5115-
Abv->Add(llvm::BitCodeAbbrevOp(llvm::BitCodeAbbrevOp::VBR, 6));
5116-
Abv->Add(llvm::BitCodeAbbrevOp(llvm::BitCodeAbbrevOp::Blob));
5117-
UpdateVisibleAbbrev = Stream.EmitAbbrev(std::move(Abv));
5118-
}
5119-
5120-
RecordData DeclUpdatesOffsetsRecord;
5121-
5122-
// Keep writing types, declarations, and declaration update records
5123-
// until we've emitted all of them.
5124-
Stream.EnterSubblock(DECLTYPES_BLOCK_ID, /*bits for abbreviations*/5);
5125-
DeclTypesBlockStartOffset = Stream.GetCurrentBitNo();
5126-
WriteTypeAbbrevs();
5127-
WriteDeclAbbrevs();
5128-
do {
5129-
WriteDeclUpdatesBlocks(DeclUpdatesOffsetsRecord);
5130-
while (!DeclTypesToEmit.empty()) {
5131-
DeclOrType DOT = DeclTypesToEmit.front();
5132-
DeclTypesToEmit.pop();
5133-
if (DOT.isType())
5134-
WriteType(DOT.getType());
5135-
else
5136-
WriteDecl(Context, DOT.getDecl());
5137-
}
5138-
} while (!DeclUpdates.empty());
5139-
Stream.ExitBlock();
5140-
5141-
DoneWritingDeclsAndTypes = true;
5142-
5143-
// These things can only be done once we've written out decls and types.
5144-
WriteTypeDeclOffsets();
5145-
if (!DeclUpdatesOffsetsRecord.empty())
5146-
Stream.EmitRecord(DECL_UPDATE_OFFSETS, DeclUpdatesOffsetsRecord);
5147-
5148-
// Create a lexical update block containing all of the declarations in the
5149-
// translation unit that do not come from other AST files.
5150-
{
5151-
SmallVector<uint32_t, 128> NewGlobalKindDeclPairs;
5152-
for (const auto *D : TU->noload_decls()) {
5153-
if (!D->isFromASTFile()) {
5154-
NewGlobalKindDeclPairs.push_back(D->getKind());
5155-
NewGlobalKindDeclPairs.push_back(GetDeclRef(D));
5156-
}
5157-
}
5158-
5159-
auto Abv = std::make_shared<BitCodeAbbrev>();
5160-
Abv->Add(llvm::BitCodeAbbrevOp(TU_UPDATE_LEXICAL));
5161-
Abv->Add(llvm::BitCodeAbbrevOp(llvm::BitCodeAbbrevOp::Blob));
5162-
unsigned TuUpdateLexicalAbbrev = Stream.EmitAbbrev(std::move(Abv));
5163-
5164-
RecordData::value_type Record[] = {TU_UPDATE_LEXICAL};
5165-
Stream.EmitRecordWithBlob(TuUpdateLexicalAbbrev, Record,
5166-
bytes(NewGlobalKindDeclPairs));
5167-
}
5168-
5169-
// And a visible updates block for the translation unit.
5170-
WriteDeclContextVisibleUpdate(TU);
5171-
5172-
// If we have any extern "C" names, write out a visible update for them.
5173-
if (Context.ExternCContext)
5174-
WriteDeclContextVisibleUpdate(Context.ExternCContext);
5110+
WriteDeclAndTypes(Context);
51755111

51765112
WriteFileDeclIDsMap();
51775113
WriteSourceManagerBlock(Context.getSourceManager(), PP);
@@ -5257,10 +5193,6 @@ ASTFileSignature ASTWriter::WriteASTCore(Sema &SemaRef, StringRef isysroot,
52575193
if (!DeleteExprsToAnalyze.empty())
52585194
Stream.EmitRecord(DELETE_EXPRS_TO_ANALYZE, DeleteExprsToAnalyze);
52595195

5260-
// Write the visible updates to DeclContexts.
5261-
for (auto *DC : UpdatedDeclContexts)
5262-
WriteDeclContextVisibleUpdate(DC);
5263-
52645196
if (!WritingModule) {
52655197
// Write the submodules that were imported, if any.
52665198
struct ModuleInfo {
@@ -5325,6 +5257,72 @@ ASTFileSignature ASTWriter::WriteASTCore(Sema &SemaRef, StringRef isysroot,
53255257
return backpatchSignature();
53265258
}
53275259

5260+
void ASTWriter::WriteDeclAndTypes(ASTContext &Context) {
5261+
// Keep writing types, declarations, and declaration update records
5262+
// until we've emitted all of them.
5263+
RecordData DeclUpdatesOffsetsRecord;
5264+
Stream.EnterSubblock(DECLTYPES_BLOCK_ID, /*bits for abbreviations*/5);
5265+
DeclTypesBlockStartOffset = Stream.GetCurrentBitNo();
5266+
WriteTypeAbbrevs();
5267+
WriteDeclAbbrevs();
5268+
do {
5269+
WriteDeclUpdatesBlocks(DeclUpdatesOffsetsRecord);
5270+
while (!DeclTypesToEmit.empty()) {
5271+
DeclOrType DOT = DeclTypesToEmit.front();
5272+
DeclTypesToEmit.pop();
5273+
if (DOT.isType())
5274+
WriteType(DOT.getType());
5275+
else
5276+
WriteDecl(Context, DOT.getDecl());
5277+
}
5278+
} while (!DeclUpdates.empty());
5279+
Stream.ExitBlock();
5280+
5281+
DoneWritingDeclsAndTypes = true;
5282+
5283+
// These things can only be done once we've written out decls and types.
5284+
WriteTypeDeclOffsets();
5285+
if (!DeclUpdatesOffsetsRecord.empty())
5286+
Stream.EmitRecord(DECL_UPDATE_OFFSETS, DeclUpdatesOffsetsRecord);
5287+
5288+
const TranslationUnitDecl *TU = Context.getTranslationUnitDecl();
5289+
// Create a lexical update block containing all of the declarations in the
5290+
// translation unit that do not come from other AST files.
5291+
SmallVector<uint32_t, 128> NewGlobalKindDeclPairs;
5292+
for (const auto *D : TU->noload_decls()) {
5293+
if (!D->isFromASTFile()) {
5294+
NewGlobalKindDeclPairs.push_back(D->getKind());
5295+
NewGlobalKindDeclPairs.push_back(GetDeclRef(D));
5296+
}
5297+
}
5298+
5299+
auto Abv = std::make_shared<llvm::BitCodeAbbrev>();
5300+
Abv->Add(llvm::BitCodeAbbrevOp(TU_UPDATE_LEXICAL));
5301+
Abv->Add(llvm::BitCodeAbbrevOp(llvm::BitCodeAbbrevOp::Blob));
5302+
unsigned TuUpdateLexicalAbbrev = Stream.EmitAbbrev(std::move(Abv));
5303+
5304+
RecordData::value_type Record[] = {TU_UPDATE_LEXICAL};
5305+
Stream.EmitRecordWithBlob(TuUpdateLexicalAbbrev, Record,
5306+
bytes(NewGlobalKindDeclPairs));
5307+
5308+
Abv = std::make_shared<llvm::BitCodeAbbrev>();
5309+
Abv->Add(llvm::BitCodeAbbrevOp(UPDATE_VISIBLE));
5310+
Abv->Add(llvm::BitCodeAbbrevOp(llvm::BitCodeAbbrevOp::VBR, 6));
5311+
Abv->Add(llvm::BitCodeAbbrevOp(llvm::BitCodeAbbrevOp::Blob));
5312+
UpdateVisibleAbbrev = Stream.EmitAbbrev(std::move(Abv));
5313+
5314+
// And a visible updates block for the translation unit.
5315+
WriteDeclContextVisibleUpdate(TU);
5316+
5317+
// If we have any extern "C" names, write out a visible update for them.
5318+
if (Context.ExternCContext)
5319+
WriteDeclContextVisibleUpdate(Context.ExternCContext);
5320+
5321+
// Write the visible updates to DeclContexts.
5322+
for (auto *DC : UpdatedDeclContexts)
5323+
WriteDeclContextVisibleUpdate(DC);
5324+
}
5325+
53285326
void ASTWriter::WriteDeclUpdatesBlocks(RecordDataImpl &OffsetsRecord) {
53295327
if (DeclUpdates.empty())
53305328
return;

clang/lib/Serialization/GeneratePCH.cpp

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
#include "clang/AST/ASTContext.h"
1515
#include "clang/Frontend/FrontendDiagnostic.h"
1616
#include "clang/Lex/HeaderSearch.h"
17+
#include "clang/Lex/HeaderSearchOptions.h"
1718
#include "clang/Lex/Preprocessor.h"
1819
#include "clang/Sema/SemaConsumer.h"
1920
#include "clang/Serialization/ASTReader.h"
@@ -23,8 +24,8 @@
2324
using namespace clang;
2425

2526
PCHGenerator::PCHGenerator(
26-
const Preprocessor &PP, InMemoryModuleCache &ModuleCache,
27-
StringRef OutputFile, StringRef isysroot, std::shared_ptr<PCHBuffer> Buffer,
27+
Preprocessor &PP, InMemoryModuleCache &ModuleCache, StringRef OutputFile,
28+
StringRef isysroot, std::shared_ptr<PCHBuffer> Buffer,
2829
ArrayRef<std::shared_ptr<ModuleFileExtension>> Extensions,
2930
bool AllowASTWithErrors, bool IncludeTimestamps,
3031
bool BuildingImplicitModule, bool ShouldCacheASTInMemory,
@@ -88,7 +89,7 @@ ASTDeserializationListener *PCHGenerator::GetASTDeserializationListener() {
8889
return &Writer;
8990
}
9091

91-
ReducedBMIGenerator::ReducedBMIGenerator(const Preprocessor &PP,
92+
ReducedBMIGenerator::ReducedBMIGenerator(Preprocessor &PP,
9293
InMemoryModuleCache &ModuleCache,
9394
StringRef OutputFile)
9495
: PCHGenerator(
@@ -107,6 +108,18 @@ Module *ReducedBMIGenerator::getEmittingModule(ASTContext &Ctx) {
107108
}
108109

109110
void ReducedBMIGenerator::HandleTranslationUnit(ASTContext &Ctx) {
111+
// We need to do this to make sure the size of reduced BMI not to be larger
112+
// than full BMI.
113+
//
114+
// FIMXE: We'd better to wrap such options to a new class ASTWriterOptions
115+
// since this is not about searching header really.
116+
// FIXME2: We'd better to move the class writing full BMI with reduced BMI.
117+
HeaderSearchOptions &HSOpts =
118+
getPreprocessor().getHeaderSearchInfo().getHeaderSearchOpts();
119+
HSOpts.ModulesSkipDiagnosticOptions = true;
120+
HSOpts.ModulesSkipHeaderSearchPaths = true;
121+
HSOpts.ModulesSkipPragmaDiagnosticMappings = true;
122+
110123
PCHGenerator::HandleTranslationUnit(Ctx);
111124

112125
if (!isComplete())

clang/test/Misc/win32-elf.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
// Check that basic use of win32-elf targets works.
2+
// RUN: %clang -fsyntax-only -target x86_64-pc-win32-elf %s
3+
4+
// RUN: %clang -fsyntax-only -target x86_64-pc-win32-elf -g %s -### 2>&1 | FileCheck %s -check-prefix=DEBUG-INFO
5+
// DEBUG-INFO: -dwarf-version={{.*}}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
// Ensure that the size of the reduced BMI is not larger than the full BMI
2+
// in the most simple case.
3+
4+
// This test requires linux commands.
5+
// REQUIRES: system-linux
6+
7+
// RUN: rm -fr %t
8+
// RUN: mkdir %t
9+
//
10+
// RUN: %clang_cc1 -std=c++20 -emit-module-interface %s -o %t/a.pcm
11+
// RUN: %clang_cc1 -std=c++20 -emit-reduced-module-interface %s -o %t/a.reduced.pcm
12+
//
13+
// %s implies the current source file. So we can't use it directly.
14+
// RUN: [ $(stat -c%\s "%t/a.pcm") -le $(stat -c%\s "%t/a.reduced.pcm") ]
15+
16+
export module a;

clang/test/Sema/code_align.c

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,17 @@ void foo1(int A)
6262
[[clang::code_align(64)]] // expected-error{{conflicting loop attribute 'code_align'}}
6363
for(int I=0; I<128; ++I) { bar(I); }
6464

65+
[[clang::code_align(4)]] // expected-note{{previous attribute is here}}
66+
[[clang::code_align(4)]] // OK
67+
[[clang::code_align(8)]] // expected-error{{conflicting loop attribute 'code_align'}}
68+
for(int I=0; I<128; ++I) { bar(I); }
69+
70+
[[clang::code_align(4)]] // expected-note 2{{previous attribute is here}}
71+
[[clang::code_align(4)]] // OK
72+
[[clang::code_align(8)]] // expected-error{{conflicting loop attribute 'code_align'}}
73+
[[clang::code_align(64)]] // expected-error{{conflicting loop attribute 'code_align'}}
74+
for(int I=0; I<128; ++I) { bar(I); }
75+
6576
// expected-error@+1{{'code_align' attribute requires an integer argument which is a constant power of two between 1 and 4096 inclusive; provided argument was 7}}
6677
[[clang::code_align(7)]]
6778
for(int I=0; I<128; ++I) { bar(I); }
@@ -135,6 +146,17 @@ void code_align_dependent() {
135146
[[clang::code_align(E)]] // cpp-local-error{{conflicting loop attribute 'code_align'}}
136147
for(int I=0; I<128; ++I) { bar(I); }
137148

149+
[[clang::code_align(A)]] // cpp-local-note{{previous attribute is here}}
150+
[[clang::code_align(A)]] // OK
151+
[[clang::code_align(E)]] // cpp-local-error{{conflicting loop attribute 'code_align'}}
152+
for(int I=0; I<128; ++I) { bar(I); }
153+
154+
[[clang::code_align(A)]] // cpp-local-note 2{{previous attribute is here}}
155+
[[clang::code_align(A)]] // OK
156+
[[clang::code_align(C)]] // cpp-local-error{{conflicting loop attribute 'code_align'}}
157+
[[clang::code_align(E)]] // cpp-local-error{{conflicting loop attribute 'code_align'}}
158+
for(int I=0; I<128; ++I) { bar(I); }
159+
138160
// cpp-local-error@+1{{'code_align' attribute requires an integer argument which is a constant power of two between 1 and 4096 inclusive; provided argument was 23}}
139161
[[clang::code_align(B)]]
140162
for(int I=0; I<128; ++I) { bar(I); }

0 commit comments

Comments
 (0)