Commit e347e266 authored by Mike Stanton's avatar Mike Stanton Committed by Commit Bot

[ptr-compr] Fix macro assembler test for CFI failure

Use the GeneratedCode construct in the EmbeddedObj test to ensure
clang with cfi support is happy.

Bug: v8:7703
Change-Id: Ib80add62127049ee5a763c6a4320add11682395d
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1611537Reviewed-by: 's avatarIgor Sheludko <ishell@chromium.org>
Commit-Queue: Michael Stanton <mvstanton@chromium.org>
Cr-Commit-Position: refs/heads/master@{#61470}
parent 41897941
......@@ -454,9 +454,9 @@ TEST(EmbeddedObj) {
StdoutStream os;
code->Print(os);
#endif
typedef int64_t (*myF0)();
myF0 f = FUNCTION_CAST<myF0>(code->entry());
Object result = static_cast<Object>(f());
typedef Object(myF0)();
auto f = GeneratedCode<myF0>::FromAddress(isolate, code->entry());
Object result = f.Call();
CHECK_EQ(old_array->ptr(), result.ptr());
// Collect garbage to ensure reloc info can be walked by the heap.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment