Skip to content

Commit 3bce8a4

Browse files
committed
Updated to work with latest AsmJit
1 parent f8c7ead commit 3bce8a4

File tree

2 files changed

+70
-69
lines changed

2 files changed

+70
-69
lines changed

.github/workflows/build.yml

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -13,36 +13,38 @@ jobs:
1313
fail-fast: false
1414
matrix:
1515
include:
16-
- { title: "diag-analyze" , host: "ubuntu-latest" , arch: "x64" , cc: "clang" , conf: "Debug" , diagnostics: "analyze-build", defs: "ASMJIT_DIR=../asmjit" }
17-
- { title: "diag-asan" , host: "ubuntu-latest" , arch: "x64" , cc: "clang" , conf: "Release", diagnostics: "address" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
18-
- { title: "diag-msan" , host: "ubuntu-latest" , arch: "x64" , cc: "clang" , conf: "Release", diagnostics: "memory" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
19-
- { title: "diag-ubsan" , host: "ubuntu-latest" , arch: "x64" , cc: "clang" , conf: "Release", diagnostics: "undefined" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
20-
- { title: "diag-valgrind" , host: "ubuntu-latest" , arch: "x64" , cc: "clang" , conf: "Release", diagnostics: "valgrind" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
21-
22-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "gcc-12" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
23-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "gcc-12" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
24-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "gcc-12" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
25-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "gcc-12" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
26-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "gcc-13" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
27-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "gcc-13" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
28-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "gcc-13" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
29-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "gcc-13" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
30-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "clang-17", conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
31-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "clang-17", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
32-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "clang-17", conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
33-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "clang-17", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
34-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "clang-18", conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
35-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "clang-18", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
36-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "clang-18", conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
37-
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "clang-18", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
38-
- { title: "macos" , host: "macos-13" , arch: "x64" , cc: "gcc-14" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
39-
- { title: "macos" , host: "macos-13" , arch: "x64" , cc: "gcc-14" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
40-
- { title: "macos" , host: "macos-13" , arch: "x64" , cc: "clang" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
41-
- { title: "macos" , host: "macos-13" , arch: "x64" , cc: "clang" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
42-
- { title: "windows" , host: "windows-2022" , arch: "x86" , cc: "vs2022" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
43-
- { title: "windows" , host: "windows-2022" , arch: "x86" , cc: "vs2022" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
44-
- { title: "windows" , host: "windows-2022" , arch: "x64" , cc: "vs2022" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
45-
- { title: "windows" , host: "windows-2022" , arch: "x64" , cc: "vs2022" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=ON" }
16+
- { title: "diag-analyze" , host: "ubuntu-latest" , arch: "x64" , cc: "clang-19", conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=0", diagnostics: "analyze-build" }
17+
- { title: "diag-asan" , host: "ubuntu-latest" , arch: "x64" , cc: "clang-19", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1", diagnostics: "asan" }
18+
- { title: "diag-msan" , host: "ubuntu-latest" , arch: "x64" , cc: "clang-19", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1", diagnostics: "msan" }
19+
- { title: "diag-ubsan" , host: "ubuntu-latest" , arch: "x64" , cc: "clang-19", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1", diagnostics: "ubsan" }
20+
- { title: "diag-hardened" , host: "ubuntu-latest" , arch: "x64" , cc: "clang-19", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1", diagnostics: "hardened" }
21+
- { title: "diag-valgrind" , host: "ubuntu-latest" , arch: "x64" , cc: "clang-19", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1", diagnostics: "valgrind" }
22+
- { title: "lang-c++20" , host: "ubuntu-latest" , arch: "x64" , cc: "clang-19", conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1,CMAKE_CXX_FLAGS=-std=c++20" }
23+
- { title: "lang-c++23" , host: "ubuntu-latest" , arch: "x64" , cc: "clang-19", conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1,CMAKE_CXX_FLAGS=-std=c++23" }
24+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "gcc-12" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
25+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "gcc-12" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
26+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "gcc-12" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
27+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "gcc-12" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
28+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "gcc-13" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
29+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "gcc-13" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
30+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "gcc-13" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
31+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "gcc-13" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
32+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "clang-17", conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
33+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "clang-17", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
34+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "clang-17", conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
35+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "clang-17", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
36+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "clang-18", conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
37+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x86" , cc: "clang-18", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
38+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "clang-18", conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
39+
- { title: "linux" , host: "ubuntu-22.04" , arch: "x64" , cc: "clang-18", conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
40+
- { title: "macos" , host: "macos-13" , arch: "x64" , cc: "gcc-14" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
41+
- { title: "macos" , host: "macos-13" , arch: "x64" , cc: "gcc-14" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
42+
- { title: "macos" , host: "macos-13" , arch: "x64" , cc: "clang" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
43+
- { title: "macos" , host: "macos-13" , arch: "x64" , cc: "clang" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
44+
- { title: "windows" , host: "windows-2022" , arch: "x86" , cc: "vs2022" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
45+
- { title: "windows" , host: "windows-2022" , arch: "x86" , cc: "vs2022" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
46+
- { title: "windows" , host: "windows-2022" , arch: "x64" , cc: "vs2022" , conf: "Debug" , defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
47+
- { title: "windows" , host: "windows-2022" , arch: "x64" , cc: "vs2022" , conf: "Release", defs: "ASMJIT_DIR=../asmjit,ASMTK_TEST=1" }
4648

4749
name: "${{matrix.title}}/${{matrix.arch}}, ${{matrix.cc}} ${{matrix.conf}}"
4850
runs-on: "${{matrix.host}}"
@@ -71,13 +73,11 @@ jobs:
7173
python-version: "3.x"
7274

7375
- name: "Build & Test"
74-
if: ${{!matrix.host}}
7576
run: python build-actions/action.py
76-
--step=all
77-
--compiler=${{matrix.cc}}
78-
--architecture=${{matrix.arch}}
7977
--source-dir=asmtk
8078
--config=asmtk/.github/workflows/build-config.json
81-
--problem-matcher=auto
82-
--build-type=${{matrix.build_type}}
79+
--compiler=${{matrix.cc}}
80+
--diagnostics=${{matrix.diagnostics}}
81+
--architecture=${{matrix.arch}}
82+
--build-type=${{matrix.conf}}
8383
--build-defs=${{matrix.defs}}

src/asmtk/asmparser.cpp

Lines changed: 34 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -114,10 +114,10 @@ static uint32_t x86RegisterCount(Arch arch, RegType regType) noexcept {
114114
if (arch == Arch::kX86)
115115
return 8;
116116

117-
if (regType == RegType::kX86_St || regType == RegType::kX86_Mm || regType == RegType::kX86_KReg || regType == RegType::kX86_Tmm)
117+
if (regType == RegType::kX86_St || regType == RegType::kX86_Mm || regType == RegType::kMask || regType == RegType::kTile)
118118
return 8;
119119

120-
if (regType == RegType::kX86_Xmm || regType == RegType::kX86_Ymm || regType == RegType::kX86_Zmm)
120+
if (regType == RegType::kVec128 || regType == RegType::kVec256 || regType == RegType::kVec512)
121121
return 32;
122122

123123
return 16;
@@ -177,25 +177,25 @@ static bool x86ParseRegister(AsmParser& parser, Operand_& op, const uint8_t* s,
177177
if (c0 <= 'd') {
178178
rId = gpLetterToRegIndex[c0 - 'a'];
179179

180-
rType = RegType::kX86_GpbLo;
180+
rType = RegType::kGp8Lo;
181181
if (c1 == 'l') goto Done;
182182

183-
rType = RegType::kX86_GpbHi;
183+
rType = RegType::kGp8Hi;
184184
if (c1 == 'h') goto Done;
185185

186-
rType = RegType::kX86_Gpw;
186+
rType = RegType::kGp16;
187187
if (c1 == 'x') goto Done;
188188
}
189189

190190
if (c1 == 's') {
191191
rId = srLetterToRegIndex[c0 - 'a'];
192-
rType = RegType::kX86_SReg;
192+
rType = RegType::kSegment;
193193

194194
if (rId != x86::Reg::kIdBad)
195195
goto Done;
196196
}
197197

198-
rType = RegType::kX86_Gpw;
198+
rType = RegType::kGp16;
199199
goto TrySpBpSiDi;
200200
}
201201

@@ -206,16 +206,16 @@ static bool x86ParseRegister(AsmParser& parser, Operand_& op, const uint8_t* s,
206206
// [RIP]
207207
if (size == 3) {
208208
if (c2 == 'l') {
209-
rType = RegType::kX86_GpbLo;
209+
rType = RegType::kGp8Lo;
210210
goto TrySpBpSiDi;
211211
}
212212

213213
if (c0 == 'e' || c0 == 'r') {
214214
cn = (c1 << 8) | c2;
215-
rType = (c0 == 'e') ? RegType::kX86_Gpd : RegType::kX86_Gpq;
215+
rType = (c0 == 'e') ? RegType::kGp32 : RegType::kGp64;
216216

217217
if (c0 == 'r' && cn == COMB_CHAR_2('i', 'p')) {
218-
rType = RegType::kX86_Rip;
218+
rType = RegType::kPC;
219219
goto Done;
220220
}
221221

@@ -235,27 +235,27 @@ static bool x86ParseRegister(AsmParser& parser, Operand_& op, const uint8_t* s,
235235
// [R?|R?B|R?W|R?D]
236236
if (c0 == 'r') {
237237
s++;
238-
rType = RegType::kX86_Gpq;
238+
rType = RegType::kGp64;
239239

240240
// Handle 'b', 'w', and 'd' suffixes.
241241
c2 = Support::asciiToLower<uint32_t>(sEnd[-1]);
242242
if (c2 == 'b')
243-
rType = RegType::kX86_GpbLo;
243+
rType = RegType::kGp8Lo;
244244
else if (c2 == 'w')
245-
rType = RegType::kX86_Gpw;
245+
rType = RegType::kGp16;
246246
else if (c2 == 'd')
247-
rType = RegType::kX86_Gpd;
248-
sEnd -= (rType != RegType::kX86_Gpq);
247+
rType = RegType::kGp32;
248+
sEnd -= (rType != RegType::kGp64);
249249
}
250250
// [XMM?|YMM?|ZMM?]
251251
else if (c0 >= 'x' && c0 <= 'z' && c1 == 'm' && c2 == 'm') {
252252
s += 3;
253-
rType = RegType(uint32_t(RegType::kX86_Xmm) + uint32_t(c0 - 'x'));
253+
rType = RegType(uint32_t(RegType::kVec128) + uint32_t(c0 - 'x'));
254254
}
255255
// [K?]
256256
else if (c0 == 'k') {
257257
s++;
258-
rType = RegType::kX86_KReg;
258+
rType = RegType::kMask;
259259
}
260260
// [ST?|FP?]
261261
else if ((c0 == 's' && c1 == 't') | (c0 == 'f' && c1 == 'p')) {
@@ -275,17 +275,17 @@ static bool x86ParseRegister(AsmParser& parser, Operand_& op, const uint8_t* s,
275275
// [TMM?]
276276
else if (c0 == 't' && c1 == 'm' && c2 == 'm') {
277277
s += 3;
278-
rType = RegType::kX86_Tmm;
278+
rType = RegType::kTile;
279279
}
280280
// [CR?]
281281
else if (c0 == 'c' && c1 == 'r') {
282282
s += 2;
283-
rType = RegType::kX86_CReg;
283+
rType = RegType::kControl;
284284
}
285285
// [DR?]
286286
else if (c0 == 'd' && c1 == 'r') {
287287
s += 2;
288-
rType = RegType::kX86_DReg;
288+
rType = RegType::kDebug;
289289
}
290290
else {
291291
return false;
@@ -316,7 +316,7 @@ static bool x86ParseRegister(AsmParser& parser, Operand_& op, const uint8_t* s,
316316
return false;
317317

318318
Done:
319-
op._initReg(ArchTraits::byArch(Arch::kX64).regTypeToSignature(rType), rId);
319+
op._initReg(RegUtils::signatureOf(rType), rId);
320320
return true;
321321
}
322322

@@ -466,7 +466,7 @@ static Error x86ParseOperand(AsmParser& parser, Operand_& dst, AsmToken* token)
466466
if (type == AsmTokenType::kSym) {
467467
// Try register.
468468
if (x86ParseRegister(parser, dst, token->data(), token->size())) {
469-
if (!dst.as<x86::Reg>().isSReg())
469+
if (!dst.as<x86::Reg>().isSegmentReg())
470470
return kErrorOk;
471471

472472
// A segment register followed by a colon (':') describes a segment of a
@@ -502,7 +502,7 @@ static Error x86ParseOperand(AsmParser& parser, Operand_& dst, AsmToken* token)
502502
// Parse segment prefix otherwise.
503503
if (type == AsmTokenType::kSym) {
504504
// Segment register.
505-
if (!x86ParseRegister(parser, seg, token->data(), token->size()) || !seg.as<x86::Reg>().isSReg())
505+
if (!x86ParseRegister(parser, seg, token->data(), token->size()) || !seg.as<Reg>().isSegmentReg())
506506
return DebugUtils::errored(kErrorInvalidAddress);
507507

508508
type = parser.nextToken(token);
@@ -630,7 +630,7 @@ static Error x86ParseOperand(AsmParser& parser, Operand_& dst, AsmToken* token)
630630
return DebugUtils::errored(kErrorInvalidAddress);
631631

632632
// Reverse base and index if base is a vector register.
633-
if (x86::Reg::isVec(base)) {
633+
if (base.isVec()) {
634634
if (index.isReg())
635635
return DebugUtils::errored(kErrorInvalidAddress);
636636
std::swap(base, index);
@@ -642,7 +642,7 @@ static Error x86ParseOperand(AsmParser& parser, Operand_& dst, AsmToken* token)
642642
if (!Support::isUInt32(int64_t(offset)))
643643
return DebugUtils::errored(kErrorInvalidAddress64Bit);
644644

645-
if (base.as<BaseReg>().isReg(RegType::kX86_Gpq))
645+
if (base.as<Reg>().isReg(RegType::kGp64))
646646
return DebugUtils::errored(kErrorInvalidAddress64BitZeroExtension);
647647
}
648648

@@ -1042,18 +1042,20 @@ static Error x86FixupInstruction(AsmParser& parser, BaseInst& inst, Operand_* op
10421042
if (isStr) {
10431043
if (count == 0) {
10441044
OperandSignature regSignature = OperandSignature{
1045-
memSize == 1 ? x86::GpbLo::kSignature :
1046-
memSize == 2 ? x86::Gpw::kSignature :
1047-
memSize == 4 ? x86::Gpd::kSignature : x86::Gpq::kSignature};
1045+
memSize == 1 ? RegTraits<RegType::kGp8Lo>::kSignature :
1046+
memSize == 2 ? RegTraits<RegType::kGp16 >::kSignature :
1047+
memSize == 4 ? RegTraits<RegType::kGp32 >::kSignature :
1048+
RegTraits<RegType::kGp64 >::kSignature
1049+
};
10481050

10491051
// String instructions aliases.
10501052
count = 2;
10511053
switch (instId) {
10521054
case x86::Inst::kIdCmps: operands[0] = emitter->ptr_zsi(); operands[1] = emitter->ptr_zdi(); break;
10531055
case x86::Inst::kIdMovs: operands[0] = emitter->ptr_zdi(); operands[1] = emitter->ptr_zsi(); break;
10541056
case x86::Inst::kIdLods:
1055-
case x86::Inst::kIdScas: operands[0] = BaseReg(regSignature, x86::Gp::kIdAx); operands[1] = emitter->ptr_zdi(); break;
1056-
case x86::Inst::kIdStos: operands[0] = emitter->ptr_zdi(); operands[1] = BaseReg(regSignature, x86::Gp::kIdAx); break;
1057+
case x86::Inst::kIdScas: operands[0] = Reg(regSignature, x86::Gp::kIdAx); operands[1] = emitter->ptr_zdi(); break;
1058+
case x86::Inst::kIdStos: operands[0] = emitter->ptr_zdi(); operands[1] = Reg(regSignature, x86::Gp::kIdAx); break;
10571059
}
10581060
}
10591061

@@ -1121,10 +1123,9 @@ Error AsmParser::parseCommand() noexcept {
11211123
ASMJIT_PROPAGATE(_emitter->bind(label));
11221124

11231125
// Must be valid if we passed through asmHandleSymbol() and bind().
1124-
LabelEntry* le = _emitter->code()->labelEntry(label);
1125-
ASMJIT_ASSERT(le);
1126+
LabelEntry& le = _emitter->code()->labelEntry(label);
11261127

1127-
if (le->type() == LabelType::kGlobal)
1128+
if (le.labelType() == LabelType::kGlobal)
11281129
_currentGlobalLabelId = label.id();
11291130

11301131
return kErrorOk;

0 commit comments

Comments
 (0)