| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 0d4bc4c commit f6996ee
6 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -37,7 +37,7 @@ | |||
| 37 | 37 | ||
| 38 | 38 | # Reset this number to 0 on major V8 upgrades. | |
| 39 | 39 | # Increment by one for each non-official patch applied to deps/v8. | |
| 40 | - 'v8_embedder_string': '-node.14', | ||
| 40 | + 'v8_embedder_string': '-node.15', | ||
| 41 | 41 | ||
| 42 | 42 | ##### V8 defaults for Node.js ##### | |
| 43 | 43 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1668,6 +1668,20 @@ config("toolchain") { | |||
| 1668 | 1668 | # Fix build with older versions of GCC | |
| 1669 | 1669 | # Ported from v8 bazel: https://crrev.com/c/3368869 | |
| 1670 | 1670 | "-Wno-stringop-overflow", | |
| 1671 | + | ||
| 1672 | + # Fix a number of bogus errors with gcc12 | ||
| 1673 | + # TODO(miladfarca): re-evaluate for future gcc upgrades | ||
| 1674 | + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111499 | ||
| 1675 | + "-Wno-stringop-overread", | ||
| 1676 | + | ||
| 1677 | + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104336 | ||
| 1678 | + "-Wno-restrict", | ||
| 1679 | + | ||
| 1680 | + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105523 | ||
| 1681 | + "-Wno-array-bounds", | ||
| 1682 | + | ||
| 1683 | + # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108517 | ||
| 1684 | + "-Wno-nonnull", | ||
| 1671 | 1685 | ] | |
| 1672 | 1686 | } | |
| 1673 | 1687 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -4022,7 +4022,9 @@ V8_NOINLINE void FuzzerMonitor::UseAfterFree() { | |||
| 4022 | 4022 | // Use-after-free caught by ASAN. | |
| 4023 | 4023 | std::vector<bool>* storage = new std::vector<bool>(3); | |
| 4024 | 4024 | delete storage; | |
| 4025 | + #if defined(__clang__) | ||
| 4025 | 4026 | USE(storage->at(1)); | |
| 4027 | + #endif | ||
| 4026 | 4028 | } | |
| 4027 | 4029 | ||
| 4028 | 4030 | V8_NOINLINE void FuzzerMonitor::UseOfUninitializedValue() { | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -110,7 +110,7 @@ WasmCompilationResult WasmCompilationUnit::ExecuteFunctionCompilation( | |||
| 110 | 110 | case ExecutionTier::kNone: | |
| 111 | 111 | UNREACHABLE(); | |
| 112 | 112 | ||
| 113 | - case ExecutionTier::kLiftoff: | ||
| 113 | + case ExecutionTier::kLiftoff: { | ||
| 114 | 114 | // The --wasm-tier-mask-for-testing flag can force functions to be | |
| 115 | 115 | // compiled with TurboFan, and the --wasm-debug-mask-for-testing can force | |
| 116 | 116 | // them to be compiled for debugging, see documentation. | |
@@ -144,8 +144,8 @@ WasmCompilationResult WasmCompilationUnit::ExecuteFunctionCompilation( | |||
| 144 | 144 | // TODO(wasm): We could actually stop or remove the tiering unit for this | |
| 145 | 145 | // function to avoid compiling it twice with TurboFan. | |
| 146 | 146 | V8_FALLTHROUGH; | |
| 147 | - | ||
| 148 | - case ExecutionTier::kTurbofan: | ||
| 147 | + } | ||
| 148 | + case ExecutionTier::kTurbofan: { | ||
| 149 | 149 | compiler::WasmCompilationData data(func_body); | |
| 150 | 150 | data.func_index = func_index_; | |
| 151 | 151 | data.wire_bytes_storage = wire_bytes_storage; | |
@@ -165,6 +165,9 @@ WasmCompilationResult WasmCompilationUnit::ExecuteFunctionCompilation( | |||
| 165 | 165 | detected); | |
| 166 | 166 | result.for_debugging = for_debugging_; | |
| 167 | 167 | break; | |
| 168 | + } | ||
| 169 | + default: | ||
| 170 | + UNREACHABLE(); | ||
| 168 | 171 | } | |
| 169 | 172 | ||
| 170 | 173 | DCHECK(result.succeeded()); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -169,10 +169,11 @@ TEST(DispatchableTest, MessageWithUnknownProperty) { | |||
| 169 | 169 | } | |
| 170 | 170 | ||
| 171 | 171 | TEST(DispatchableTest, DuplicateMapKey) { | |
| 172 | - for (const std::string& json : | ||
| 173 | - {"{\"id\":42,\"id\":42}", "{\"params\":null,\"params\":null}", | ||
| 174 | - "{\"method\":\"foo\",\"method\":\"foo\"}", | ||
| 175 | - "{\"sessionId\":\"42\",\"sessionId\":\"42\"}"}) { | ||
| 172 | + const std::array<std::string, 4> jsons = { | ||
| 173 | + {"{\"id\":42,\"id\":42}", "{\"params\":null,\"params\":null}", | ||
| 174 | + "{\"method\":\"foo\",\"method\":\"foo\"}", | ||
| 175 | + "{\"sessionId\":\"42\",\"sessionId\":\"42\"}"}}; | ||
| 176 | + for (const std::string& json : jsons) { | ||
| 176 | 177 | SCOPED_TRACE("json = " + json); | |
| 177 | 178 | std::vector<uint8_t> cbor; | |
| 178 | 179 | ASSERT_TRUE(json::ConvertJSONToCBOR(SpanFrom(json), &cbor).ok()); | |
@@ -185,11 +186,12 @@ TEST(DispatchableTest, DuplicateMapKey) { | |||
| 185 | 186 | } | |
| 186 | 187 | ||
| 187 | 188 | TEST(DispatchableTest, ValidMessageParsesOK_NoParams) { | |
| 188 | - for (const std::string& json : | ||
| 189 | - {"{\"id\":42,\"method\":\"Foo.executeBar\",\"sessionId\":" | ||
| 190 | - "\"f421ssvaz4\"}", | ||
| 191 | - "{\"id\":42,\"method\":\"Foo.executeBar\",\"sessionId\":\"f421ssvaz4\"," | ||
| 192 | - "\"params\":null}"}) { | ||
| 189 | + const std::array<std::string, 2> jsons = { | ||
| 190 | + {"{\"id\":42,\"method\":\"Foo.executeBar\",\"sessionId\":" | ||
| 191 | + "\"f421ssvaz4\"}", | ||
| 192 | + "{\"id\":42,\"method\":\"Foo.executeBar\",\"sessionId\":\"f421ssvaz4\"," | ||
| 193 | + "\"params\":null}"}}; | ||
| 194 | + for (const std::string& json : jsons) { | ||
| 193 | 195 | SCOPED_TRACE("json = " + json); | |
| 194 | 196 | std::vector<uint8_t> cbor; | |
| 195 | 197 | ASSERT_TRUE(json::ConvertJSONToCBOR(SpanFrom(json), &cbor).ok()); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -704,15 +704,16 @@ using ContainerTestTypes = ::testing::Types<std::vector<uint8_t>, std::string>; | |||
| 704 | 704 | TYPED_TEST_SUITE(ConvertJSONToCBORTest, ContainerTestTypes); | |
| 705 | 705 | ||
| 706 | 706 | TYPED_TEST(ConvertJSONToCBORTest, RoundTripValidJson) { | |
| 707 | - for (const std::string& json_in : { | ||
| 708 | - "{\"msg\":\"Hello, world.\",\"lst\":[1,2,3]}", | ||
| 709 | - "3.1415", | ||
| 710 | - "false", | ||
| 711 | - "true", | ||
| 712 | - "\"Hello, world.\"", | ||
| 713 | - "[1,2,3]", | ||
| 714 | - "[]", | ||
| 715 | - }) { | ||
| 707 | + const std::array<std::string, 7> jsons = {{ | ||
| 708 | + "{\"msg\":\"Hello, world.\",\"lst\":[1,2,3]}", | ||
| 709 | + "3.1415", | ||
| 710 | + "false", | ||
| 711 | + "true", | ||
| 712 | + "\"Hello, world.\"", | ||
| 713 | + "[1,2,3]", | ||
| 714 | + "[]", | ||
| 715 | + }}; | ||
| 716 | + for (const std::string& json_in : jsons) { | ||
| 716 | 717 | SCOPED_TRACE(json_in); | |
| 717 | 718 | TypeParam json(json_in.begin(), json_in.end()); | |
| 718 | 719 | std::vector<uint8_t> cbor; | |
| Back | FazBrowse Home | New Git URL |
0 commit comments