dart-sdk/tools/run_offsets_extractor.sh

81 lines
2.5 KiB
Bash
Raw Normal View History

Reland "[vm] Create offsets_extractor tool." This reverts commit 224f82c21cb2966f36ab850eae7ef5c8697cc477. Reason for revert: Just need to split DBC section into 32 and 64 bit Original change's description: > Revert "[vm] Create offsets_extractor tool." > > This reverts commit 3015d79371a1cf6407e5e799354d42fc6a0dcaec. > > Reason for revert: Fails the Flutter build > /b/s/w/ir/cache/builder/mac_sdk -mmacosx-version-min=10.12 -m32 -fno-strict-aliasing -fstack-protector-all -fcolor-diagnostics -Wall -Wextra -Wendif-labels -Werror -Wno-missing-field-initializers -Wno-unused-parameter -Wunguarded-availability -fvisibility=hidden -stdlib=libc++ -Wheader-hygiene -Wstring-conversion -Wthread-safety -O2 -fno-ident -fdata-sections -ffunction-sections -g2 -Werror -Wall -Wextra -Wno-unused-parameter -Wno-unused-private-field -Wnon-virtual-dtor -Wvla -Wno-conversion-null -Woverloaded-virtual -Wno-comments -g3 -ggdb3 -fno-rtti -fno-exceptions -Wimplicit-fallthrough -O3 -fvisibility-inlines-hidden -std=c++14 -fno-rtti -fno-exceptions -c ../../third_party/dart/runtime/vm/dart.cc -o clang_x86/obj/third_party/dart/runtime/vm/libdart_vm_nosnapshot_with_precompiler.dart.o > In file included from ../../third_party/dart/runtime/vm/dart.cc:9: > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:958:50: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 576460752303423487 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word Array_kMaxElements = 576460752303423487; > ~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~ > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:965:51: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 2305843009213693951 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word String_kMaxElements = 2305843009213693951; > ~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~ > 2 errors generated. > > Change-Id: Iaf509c6ee7a2ce75664935519ac02a933a9eb2bf > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104402 > Reviewed-by: Siva Annamalai <asiva@google.com> > Commit-Queue: Siva Annamalai <asiva@google.com> > Auto-Submit: Siva Annamalai <asiva@google.com> TBR=asiva@google.com Change-Id: Ibf749ceee274b03cdffa6d7ed46fcbe75d1a1e94 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104620 Reviewed-by: Liam Appelbe <liama@google.com> Reviewed-by: Siva Annamalai <asiva@google.com> Commit-Queue: Liam Appelbe <liama@google.com>
2019-06-03 22:14:16 +00:00
#!/usr/bin/env bash
# Copyright (c) 2019, the Dart project authors. Please see the AUTHORS file
# for details. All rights reserved. Use of this source code is governed by a
# BSD-style license that can be found in the LICENSE file.
set -e
FILE="runtime/vm/compiler/runtime_offsets_extracted.h"
# Make sure we're running in the SDK directory.
if ! test -f "$FILE"; then
echo "Couldn't find $FILE"
echo "Make sure to run this script from the Dart SDK directory."
exit 1
fi
TEMP="${FILE}.temp"
TEMP_HEADER="${FILE}.header.temp"
TEMP_JIT="${FILE}.jit.temp"
TEMP_AOT="${FILE}.aot.temp"
# Remove old temp files if the previous run was stopped prematurely.
rm -rf "${TEMP}" "${TEMP_HEADER}" "${TEMP_JIT}" "${TEMP_AOT}"
# We're regenerating the file, but we want to keep all the comments etc at the
# top of the file. So just delete everything after the first "#if ".
LINE=$(grep "#if " "$FILE" -n | head -n 1 | sed "s/^\([0-9]*\):.*/\1/")
head -n $(expr $LINE - 1) "$FILE" >"$TEMP_HEADER"
Reland "[vm] Create offsets_extractor tool." This reverts commit 224f82c21cb2966f36ab850eae7ef5c8697cc477. Reason for revert: Just need to split DBC section into 32 and 64 bit Original change's description: > Revert "[vm] Create offsets_extractor tool." > > This reverts commit 3015d79371a1cf6407e5e799354d42fc6a0dcaec. > > Reason for revert: Fails the Flutter build > /b/s/w/ir/cache/builder/mac_sdk -mmacosx-version-min=10.12 -m32 -fno-strict-aliasing -fstack-protector-all -fcolor-diagnostics -Wall -Wextra -Wendif-labels -Werror -Wno-missing-field-initializers -Wno-unused-parameter -Wunguarded-availability -fvisibility=hidden -stdlib=libc++ -Wheader-hygiene -Wstring-conversion -Wthread-safety -O2 -fno-ident -fdata-sections -ffunction-sections -g2 -Werror -Wall -Wextra -Wno-unused-parameter -Wno-unused-private-field -Wnon-virtual-dtor -Wvla -Wno-conversion-null -Woverloaded-virtual -Wno-comments -g3 -ggdb3 -fno-rtti -fno-exceptions -Wimplicit-fallthrough -O3 -fvisibility-inlines-hidden -std=c++14 -fno-rtti -fno-exceptions -c ../../third_party/dart/runtime/vm/dart.cc -o clang_x86/obj/third_party/dart/runtime/vm/libdart_vm_nosnapshot_with_precompiler.dart.o > In file included from ../../third_party/dart/runtime/vm/dart.cc:9: > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:958:50: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 576460752303423487 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word Array_kMaxElements = 576460752303423487; > ~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~ > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:965:51: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 2305843009213693951 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word String_kMaxElements = 2305843009213693951; > ~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~ > 2 errors generated. > > Change-Id: Iaf509c6ee7a2ce75664935519ac02a933a9eb2bf > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104402 > Reviewed-by: Siva Annamalai <asiva@google.com> > Commit-Queue: Siva Annamalai <asiva@google.com> > Auto-Submit: Siva Annamalai <asiva@google.com> TBR=asiva@google.com Change-Id: Ibf749ceee274b03cdffa6d7ed46fcbe75d1a1e94 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104620 Reviewed-by: Liam Appelbe <liama@google.com> Reviewed-by: Siva Annamalai <asiva@google.com> Commit-Queue: Liam Appelbe <liama@google.com>
2019-06-03 22:14:16 +00:00
# Run offsets_extractor for every architecture and append the results.
run() {
tools/build.py --mode=$1 --arch=$2 offsets_extractor offsets_extractor_precompiled_runtime
echo "" >>"$TEMP_JIT"
out/$3/offsets_extractor >>"$TEMP_JIT"
echo "" >>"$TEMP_AOT"
out/$3/offsets_extractor_precompiled_runtime >>"$TEMP_AOT"
Reland "[vm] Create offsets_extractor tool." This reverts commit 224f82c21cb2966f36ab850eae7ef5c8697cc477. Reason for revert: Just need to split DBC section into 32 and 64 bit Original change's description: > Revert "[vm] Create offsets_extractor tool." > > This reverts commit 3015d79371a1cf6407e5e799354d42fc6a0dcaec. > > Reason for revert: Fails the Flutter build > /b/s/w/ir/cache/builder/mac_sdk -mmacosx-version-min=10.12 -m32 -fno-strict-aliasing -fstack-protector-all -fcolor-diagnostics -Wall -Wextra -Wendif-labels -Werror -Wno-missing-field-initializers -Wno-unused-parameter -Wunguarded-availability -fvisibility=hidden -stdlib=libc++ -Wheader-hygiene -Wstring-conversion -Wthread-safety -O2 -fno-ident -fdata-sections -ffunction-sections -g2 -Werror -Wall -Wextra -Wno-unused-parameter -Wno-unused-private-field -Wnon-virtual-dtor -Wvla -Wno-conversion-null -Woverloaded-virtual -Wno-comments -g3 -ggdb3 -fno-rtti -fno-exceptions -Wimplicit-fallthrough -O3 -fvisibility-inlines-hidden -std=c++14 -fno-rtti -fno-exceptions -c ../../third_party/dart/runtime/vm/dart.cc -o clang_x86/obj/third_party/dart/runtime/vm/libdart_vm_nosnapshot_with_precompiler.dart.o > In file included from ../../third_party/dart/runtime/vm/dart.cc:9: > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:958:50: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 576460752303423487 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word Array_kMaxElements = 576460752303423487; > ~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~ > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:965:51: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 2305843009213693951 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word String_kMaxElements = 2305843009213693951; > ~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~ > 2 errors generated. > > Change-Id: Iaf509c6ee7a2ce75664935519ac02a933a9eb2bf > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104402 > Reviewed-by: Siva Annamalai <asiva@google.com> > Commit-Queue: Siva Annamalai <asiva@google.com> > Auto-Submit: Siva Annamalai <asiva@google.com> TBR=asiva@google.com Change-Id: Ibf749ceee274b03cdffa6d7ed46fcbe75d1a1e94 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104620 Reviewed-by: Liam Appelbe <liama@google.com> Reviewed-by: Siva Annamalai <asiva@google.com> Commit-Queue: Liam Appelbe <liama@google.com>
2019-06-03 22:14:16 +00:00
}
echo "" >>"$TEMP_JIT"
echo "" >>"$TEMP_AOT"
echo "#if !defined(PRODUCT)" >>"$TEMP_JIT"
echo "#if !defined(PRODUCT)" >>"$TEMP_AOT"
run release simarm ReleaseSIMARM
run release x64 ReleaseX64
run release ia32 ReleaseIA32
run release simarm64 ReleaseSIMARM64
run release x64c ReleaseX64C
run release simarm64c ReleaseSIMARM64C
[vm] Support RISC-V. Implements a backend targeting RV32GC and RV64GC, based on Linux standardizing around GC. The assembler is written to make it easy to disable usage of C, but because the sizes of some instruction sequences are compile-time constants, an additional build configuration would need to be defined to make use of it. The assembler and disassembler cover every RV32/64GC instruction. The simulator covers all instructions except accessing CSRs and the floating point state accessible through such, include accrued exceptions and dynamic rounding mode. Quirks: - RISC-V is a compare-and-branch architecture, but some existing "architecture-independent" parts of the Dart compiler assume a condition code architecture. To avoid rewriting these parts, we use a peephole in the assembler to map to compare-and-branch. See Assembler::BranchIf. Luckily nothing depended on taking multiple branches on the same condition code set. - There are no hardware overflow checks, so we must use Hacker's Delight style software checks. Often these are very cheap: if the sign of one operand is known, a single branch is needed. - The ranges of RISC-V branches and jumps are such that we use 3 levels of generation for forward branches, instead of the 2 levels of near and far branches used on ARM[64]. Nearly all code is handled by the first two levels with 20-bits of range, with enormous regex matchers triggering the third level that uses aupic+jalr to get 32-bits of range. - For PC-relative calls in AOT, we always generate auipc+jalr pairs with 32-bits of range, so we never generate trampolines. - Only a subset of registers are available in some compressed instructions, so we assign the most popular uses to these registers. In particular, THR, TMP[2], CODE and PP. This has the effect of assigning CODE and PP to volatile registers in the C calling convention, whereas they are assigned preserved registers on the other architectures. As on ARM64, PP is untagged; this is so short indices can be accessed with a compressed instruction. - There are no push or pop instructions, so combining pushes and pops is preferred so we can update SP once. - The C calling convention has a strongly aligned stack, but unlike on ARM64 we don't need to use an alternate stack pointer. The author ensured language was added to the RISC-V psABI making the OS responsible for realigning the stack pointer for signal handlers, allowing Dart to leave the stack pointer misaligned from the C calling convention's point of view until a foreign call. - We don't bother with the link register tracking done on ARM[64]. Instead we make use of an alternate link register to avoid inline spilling in the write barrier. Unimplemented: - non-trivial FFI cases - Compressed pointers - No intention to implement. - Unboxed SIMD - We might make use of the V extension registers when the V extension is ratified. - BigInt intrinsics TEST=existing tests for IL level, new tests for assembler/disassembler/simulator Bug: https://github.com/dart-lang/sdk/issues/38587 Bug: https://github.com/dart-lang/sdk/issues/48164 Change-Id: I991d1df4be5bf55efec5371b767b332d37dfa3e0 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/217289 Reviewed-by: Alexander Markov <alexmarkov@google.com> Reviewed-by: Daco Harkes <dacoharkes@google.com> Reviewed-by: Slava Egorov <vegorov@google.com> Commit-Queue: Ryan Macnak <rmacnak@google.com>
2022-01-20 00:57:57 +00:00
run release simriscv32 ReleaseSIMRISCV32
run release simriscv64 ReleaseSIMRISCV64
echo "" >>"$TEMP_JIT"
echo "" >>"$TEMP_AOT"
echo "#else // !defined(PRODUCT)" >>"$TEMP_JIT"
echo "#else // !defined(PRODUCT)" >>"$TEMP_AOT"
run product simarm ProductSIMARM
run product x64 ProductX64
run product ia32 ProductIA32
run product simarm64 ProductSIMARM64
run product x64c ProductX64C
run product simarm64c ProductSIMARM64C
[vm] Support RISC-V. Implements a backend targeting RV32GC and RV64GC, based on Linux standardizing around GC. The assembler is written to make it easy to disable usage of C, but because the sizes of some instruction sequences are compile-time constants, an additional build configuration would need to be defined to make use of it. The assembler and disassembler cover every RV32/64GC instruction. The simulator covers all instructions except accessing CSRs and the floating point state accessible through such, include accrued exceptions and dynamic rounding mode. Quirks: - RISC-V is a compare-and-branch architecture, but some existing "architecture-independent" parts of the Dart compiler assume a condition code architecture. To avoid rewriting these parts, we use a peephole in the assembler to map to compare-and-branch. See Assembler::BranchIf. Luckily nothing depended on taking multiple branches on the same condition code set. - There are no hardware overflow checks, so we must use Hacker's Delight style software checks. Often these are very cheap: if the sign of one operand is known, a single branch is needed. - The ranges of RISC-V branches and jumps are such that we use 3 levels of generation for forward branches, instead of the 2 levels of near and far branches used on ARM[64]. Nearly all code is handled by the first two levels with 20-bits of range, with enormous regex matchers triggering the third level that uses aupic+jalr to get 32-bits of range. - For PC-relative calls in AOT, we always generate auipc+jalr pairs with 32-bits of range, so we never generate trampolines. - Only a subset of registers are available in some compressed instructions, so we assign the most popular uses to these registers. In particular, THR, TMP[2], CODE and PP. This has the effect of assigning CODE and PP to volatile registers in the C calling convention, whereas they are assigned preserved registers on the other architectures. As on ARM64, PP is untagged; this is so short indices can be accessed with a compressed instruction. - There are no push or pop instructions, so combining pushes and pops is preferred so we can update SP once. - The C calling convention has a strongly aligned stack, but unlike on ARM64 we don't need to use an alternate stack pointer. The author ensured language was added to the RISC-V psABI making the OS responsible for realigning the stack pointer for signal handlers, allowing Dart to leave the stack pointer misaligned from the C calling convention's point of view until a foreign call. - We don't bother with the link register tracking done on ARM[64]. Instead we make use of an alternate link register to avoid inline spilling in the write barrier. Unimplemented: - non-trivial FFI cases - Compressed pointers - No intention to implement. - Unboxed SIMD - We might make use of the V extension registers when the V extension is ratified. - BigInt intrinsics TEST=existing tests for IL level, new tests for assembler/disassembler/simulator Bug: https://github.com/dart-lang/sdk/issues/38587 Bug: https://github.com/dart-lang/sdk/issues/48164 Change-Id: I991d1df4be5bf55efec5371b767b332d37dfa3e0 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/217289 Reviewed-by: Alexander Markov <alexmarkov@google.com> Reviewed-by: Daco Harkes <dacoharkes@google.com> Reviewed-by: Slava Egorov <vegorov@google.com> Commit-Queue: Ryan Macnak <rmacnak@google.com>
2022-01-20 00:57:57 +00:00
run product simriscv32 ProductSIMRISCV32
run product simriscv64 ProductSIMRISCV64
echo "" >>"$TEMP_JIT"
echo "" >>"$TEMP_AOT"
echo "#endif // !defined(PRODUCT)" >>"$TEMP_JIT"
echo "#endif // !defined(PRODUCT)" >>"$TEMP_AOT"
Reland "[vm] Create offsets_extractor tool." This reverts commit 224f82c21cb2966f36ab850eae7ef5c8697cc477. Reason for revert: Just need to split DBC section into 32 and 64 bit Original change's description: > Revert "[vm] Create offsets_extractor tool." > > This reverts commit 3015d79371a1cf6407e5e799354d42fc6a0dcaec. > > Reason for revert: Fails the Flutter build > /b/s/w/ir/cache/builder/mac_sdk -mmacosx-version-min=10.12 -m32 -fno-strict-aliasing -fstack-protector-all -fcolor-diagnostics -Wall -Wextra -Wendif-labels -Werror -Wno-missing-field-initializers -Wno-unused-parameter -Wunguarded-availability -fvisibility=hidden -stdlib=libc++ -Wheader-hygiene -Wstring-conversion -Wthread-safety -O2 -fno-ident -fdata-sections -ffunction-sections -g2 -Werror -Wall -Wextra -Wno-unused-parameter -Wno-unused-private-field -Wnon-virtual-dtor -Wvla -Wno-conversion-null -Woverloaded-virtual -Wno-comments -g3 -ggdb3 -fno-rtti -fno-exceptions -Wimplicit-fallthrough -O3 -fvisibility-inlines-hidden -std=c++14 -fno-rtti -fno-exceptions -c ../../third_party/dart/runtime/vm/dart.cc -o clang_x86/obj/third_party/dart/runtime/vm/libdart_vm_nosnapshot_with_precompiler.dart.o > In file included from ../../third_party/dart/runtime/vm/dart.cc:9: > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:958:50: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 576460752303423487 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word Array_kMaxElements = 576460752303423487; > ~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~ > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:965:51: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 2305843009213693951 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word String_kMaxElements = 2305843009213693951; > ~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~ > 2 errors generated. > > Change-Id: Iaf509c6ee7a2ce75664935519ac02a933a9eb2bf > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104402 > Reviewed-by: Siva Annamalai <asiva@google.com> > Commit-Queue: Siva Annamalai <asiva@google.com> > Auto-Submit: Siva Annamalai <asiva@google.com> TBR=asiva@google.com Change-Id: Ibf749ceee274b03cdffa6d7ed46fcbe75d1a1e94 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104620 Reviewed-by: Liam Appelbe <liama@google.com> Reviewed-by: Siva Annamalai <asiva@google.com> Commit-Queue: Liam Appelbe <liama@google.com>
2019-06-03 22:14:16 +00:00
cat $TEMP_HEADER >>"$TEMP"
cat $TEMP_JIT >>"$TEMP"
cat $TEMP_AOT >>"$TEMP"
Reland "[vm] Create offsets_extractor tool." This reverts commit 224f82c21cb2966f36ab850eae7ef5c8697cc477. Reason for revert: Just need to split DBC section into 32 and 64 bit Original change's description: > Revert "[vm] Create offsets_extractor tool." > > This reverts commit 3015d79371a1cf6407e5e799354d42fc6a0dcaec. > > Reason for revert: Fails the Flutter build > /b/s/w/ir/cache/builder/mac_sdk -mmacosx-version-min=10.12 -m32 -fno-strict-aliasing -fstack-protector-all -fcolor-diagnostics -Wall -Wextra -Wendif-labels -Werror -Wno-missing-field-initializers -Wno-unused-parameter -Wunguarded-availability -fvisibility=hidden -stdlib=libc++ -Wheader-hygiene -Wstring-conversion -Wthread-safety -O2 -fno-ident -fdata-sections -ffunction-sections -g2 -Werror -Wall -Wextra -Wno-unused-parameter -Wno-unused-private-field -Wnon-virtual-dtor -Wvla -Wno-conversion-null -Woverloaded-virtual -Wno-comments -g3 -ggdb3 -fno-rtti -fno-exceptions -Wimplicit-fallthrough -O3 -fvisibility-inlines-hidden -std=c++14 -fno-rtti -fno-exceptions -c ../../third_party/dart/runtime/vm/dart.cc -o clang_x86/obj/third_party/dart/runtime/vm/libdart_vm_nosnapshot_with_precompiler.dart.o > In file included from ../../third_party/dart/runtime/vm/dart.cc:9: > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:958:50: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 576460752303423487 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word Array_kMaxElements = 576460752303423487; > ~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~ > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:965:51: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 2305843009213693951 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word String_kMaxElements = 2305843009213693951; > ~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~ > 2 errors generated. > > Change-Id: Iaf509c6ee7a2ce75664935519ac02a933a9eb2bf > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104402 > Reviewed-by: Siva Annamalai <asiva@google.com> > Commit-Queue: Siva Annamalai <asiva@google.com> > Auto-Submit: Siva Annamalai <asiva@google.com> TBR=asiva@google.com Change-Id: Ibf749ceee274b03cdffa6d7ed46fcbe75d1a1e94 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104620 Reviewed-by: Liam Appelbe <liama@google.com> Reviewed-by: Siva Annamalai <asiva@google.com> Commit-Queue: Liam Appelbe <liama@google.com>
2019-06-03 22:14:16 +00:00
echo "" >>"$TEMP"
echo "#endif // RUNTIME_VM_COMPILER_RUNTIME_OFFSETS_EXTRACTED_H_" >>"$TEMP"
mv "$TEMP" "$FILE"
# Cleanup.
Reland "[vm] Create offsets_extractor tool." This reverts commit 224f82c21cb2966f36ab850eae7ef5c8697cc477. Reason for revert: Just need to split DBC section into 32 and 64 bit Original change's description: > Revert "[vm] Create offsets_extractor tool." > > This reverts commit 3015d79371a1cf6407e5e799354d42fc6a0dcaec. > > Reason for revert: Fails the Flutter build > /b/s/w/ir/cache/builder/mac_sdk -mmacosx-version-min=10.12 -m32 -fno-strict-aliasing -fstack-protector-all -fcolor-diagnostics -Wall -Wextra -Wendif-labels -Werror -Wno-missing-field-initializers -Wno-unused-parameter -Wunguarded-availability -fvisibility=hidden -stdlib=libc++ -Wheader-hygiene -Wstring-conversion -Wthread-safety -O2 -fno-ident -fdata-sections -ffunction-sections -g2 -Werror -Wall -Wextra -Wno-unused-parameter -Wno-unused-private-field -Wnon-virtual-dtor -Wvla -Wno-conversion-null -Woverloaded-virtual -Wno-comments -g3 -ggdb3 -fno-rtti -fno-exceptions -Wimplicit-fallthrough -O3 -fvisibility-inlines-hidden -std=c++14 -fno-rtti -fno-exceptions -c ../../third_party/dart/runtime/vm/dart.cc -o clang_x86/obj/third_party/dart/runtime/vm/libdart_vm_nosnapshot_with_precompiler.dart.o > In file included from ../../third_party/dart/runtime/vm/dart.cc:9: > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:958:50: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 576460752303423487 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word Array_kMaxElements = 576460752303423487; > ~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~ > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:965:51: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 2305843009213693951 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word String_kMaxElements = 2305843009213693951; > ~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~ > 2 errors generated. > > Change-Id: Iaf509c6ee7a2ce75664935519ac02a933a9eb2bf > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104402 > Reviewed-by: Siva Annamalai <asiva@google.com> > Commit-Queue: Siva Annamalai <asiva@google.com> > Auto-Submit: Siva Annamalai <asiva@google.com> TBR=asiva@google.com Change-Id: Ibf749ceee274b03cdffa6d7ed46fcbe75d1a1e94 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104620 Reviewed-by: Liam Appelbe <liama@google.com> Reviewed-by: Siva Annamalai <asiva@google.com> Commit-Queue: Liam Appelbe <liama@google.com>
2019-06-03 22:14:16 +00:00
git cl format "$FILE"
rm "$TEMP_HEADER"
rm "$TEMP_JIT"
rm "$TEMP_AOT"
Reland "[vm] Create offsets_extractor tool." This reverts commit 224f82c21cb2966f36ab850eae7ef5c8697cc477. Reason for revert: Just need to split DBC section into 32 and 64 bit Original change's description: > Revert "[vm] Create offsets_extractor tool." > > This reverts commit 3015d79371a1cf6407e5e799354d42fc6a0dcaec. > > Reason for revert: Fails the Flutter build > /b/s/w/ir/cache/builder/mac_sdk -mmacosx-version-min=10.12 -m32 -fno-strict-aliasing -fstack-protector-all -fcolor-diagnostics -Wall -Wextra -Wendif-labels -Werror -Wno-missing-field-initializers -Wno-unused-parameter -Wunguarded-availability -fvisibility=hidden -stdlib=libc++ -Wheader-hygiene -Wstring-conversion -Wthread-safety -O2 -fno-ident -fdata-sections -ffunction-sections -g2 -Werror -Wall -Wextra -Wno-unused-parameter -Wno-unused-private-field -Wnon-virtual-dtor -Wvla -Wno-conversion-null -Woverloaded-virtual -Wno-comments -g3 -ggdb3 -fno-rtti -fno-exceptions -Wimplicit-fallthrough -O3 -fvisibility-inlines-hidden -std=c++14 -fno-rtti -fno-exceptions -c ../../third_party/dart/runtime/vm/dart.cc -o clang_x86/obj/third_party/dart/runtime/vm/libdart_vm_nosnapshot_with_precompiler.dart.o > In file included from ../../third_party/dart/runtime/vm/dart.cc:9: > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:958:50: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 576460752303423487 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word Array_kMaxElements = 576460752303423487; > ~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~ > ../../third_party/dart/runtime/vm/compiler/runtime_offsets_extracted.h:965:51: error: implicit conversion from 'long long' to 'const dart::word' (aka 'const long') changes value from 2305843009213693951 to -1 [-Werror,-Wconstant-conversion] > static constexpr dart::word String_kMaxElements = 2305843009213693951; > ~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~~~ > 2 errors generated. > > Change-Id: Iaf509c6ee7a2ce75664935519ac02a933a9eb2bf > Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104402 > Reviewed-by: Siva Annamalai <asiva@google.com> > Commit-Queue: Siva Annamalai <asiva@google.com> > Auto-Submit: Siva Annamalai <asiva@google.com> TBR=asiva@google.com Change-Id: Ibf749ceee274b03cdffa6d7ed46fcbe75d1a1e94 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/104620 Reviewed-by: Liam Appelbe <liama@google.com> Reviewed-by: Siva Annamalai <asiva@google.com> Commit-Queue: Liam Appelbe <liama@google.com>
2019-06-03 22:14:16 +00:00
echo -e "\n\nSuccessfully generated $FILE :)"