Skip to content

Commit

Permalink
Revert Reland '[vm/ffi] Implement FFI callbacks on AOT for ELF and As…
Browse files Browse the repository at this point in the history
…m snapshots (excl. blobs).' as it breaks flutter profile execution on ios 32-bit platform.

Fixes flutter/flutter#40114

Change-Id: If8d71e9c19c2e794d29f7ecbacb87457890a2fd5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/116883
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Alexander Aprelev <aam@google.com>
  • Loading branch information
aam authored and commit-bot@chromium.org committed Sep 12, 2019
1 parent fa9a387 commit e27ceb5
Show file tree
Hide file tree
Showing 7 changed files with 5 additions and 35 deletions.
25 changes: 0 additions & 25 deletions assembler.cc
Original file line number Diff line number Diff line change
Expand Up @@ -30,31 +30,6 @@ DEFINE_FLAG(bool, use_far_branches, false, "Enable far branches for ARM.");

namespace compiler {

AssemblerBase::~AssemblerBase() {}

intptr_t AssemblerBase::InsertAlignedRelocation(BSS::Relocation reloc) {
// We cannot put a relocation at the very start (it's not a valid
// instruction)!
ASSERT(CodeSize() != 0);

// Align to a target word boundary.
const intptr_t offset =
Utils::RoundUp(CodeSize(), compiler::target::kWordSize);

while (CodeSize() < offset) {
Breakpoint();
}
ASSERT(CodeSize() == offset);

AssemblerBuffer::EnsureCapacity ensured(&buffer_);
buffer_.Emit<compiler::target::word>(BSS::RelocationIndex(reloc) *
compiler::target::kWordSize);

ASSERT(CodeSize() == (offset + compiler::target::kWordSize));

return offset;
}

static uword NewContents(intptr_t capacity) {
Zone* zone = Thread::Current()->zone();
uword result = zone->AllocUnsafe(capacity);
Expand Down
6 changes: 1 addition & 5 deletions assembler.h
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ class AssemblerBase : public StackResource {
prologue_offset_(-1),
has_single_entry_point_(true),
object_pool_builder_(object_pool_builder) {}
virtual ~AssemblerBase();
virtual ~AssemblerBase() {}

intptr_t CodeSize() const { return buffer_.Size(); }

Expand All @@ -320,10 +320,6 @@ class AssemblerBase : public StackResource {
void Comment(const char* format, ...) PRINTF_ATTRIBUTE(2, 3);
static bool EmittingComments();

virtual void Breakpoint() = 0;

intptr_t InsertAlignedRelocation(BSS::Relocation reloc);

void Unimplemented(const char* message);
void Untested(const char* message);
void Unreachable(const char* message);
Expand Down
2 changes: 1 addition & 1 deletion assembler_arm.h
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,7 @@ class Assembler : public AssemblerBase {
#endif // TESTING || DEBUG

// Debugging and bringup support.
void Breakpoint() override { bkpt(0); }
void Breakpoint() { bkpt(0); }
void Stop(const char* message) override;

static void InitializeMemoryWithBreakpoints(uword data, intptr_t length);
Expand Down
2 changes: 1 addition & 1 deletion assembler_arm64.h
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ class Assembler : public AssemblerBase {
void set_use_far_branches(bool b) { use_far_branches_ = b; }

// Debugging and bringup support.
void Breakpoint() override { brk(0); }
void Breakpoint() { brk(0); }
void Stop(const char* message) override;

static void InitializeMemoryWithBreakpoints(uword data, intptr_t length);
Expand Down
1 change: 0 additions & 1 deletion assembler_dbc.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ class Assembler : public AssemblerBase {
void MonomorphicCheckedEntryAOT() {}

// Debugging and bringup support.
void Breakpoint() override { Stop("Breakpoint!"); }
void Stop(const char* message) override;

static void InitializeMemoryWithBreakpoints(uword data, intptr_t length);
Expand Down
2 changes: 1 addition & 1 deletion assembler_ia32.h
Original file line number Diff line number Diff line change
Expand Up @@ -835,7 +835,7 @@ class Assembler : public AssemblerBase {
Register temp);

// Debugging and bringup support.
void Breakpoint() override { int3(); }
void Breakpoint() { int3(); }
void Stop(const char* message) override;

static void InitializeMemoryWithBreakpoints(uword data, intptr_t length);
Expand Down
2 changes: 1 addition & 1 deletion assembler_x64.h
Original file line number Diff line number Diff line change
Expand Up @@ -936,7 +936,7 @@ class Assembler : public AssemblerBase {
void GenerateUnRelocatedPcRelativeCall(intptr_t offset_into_target = 0);

// Debugging and bringup support.
void Breakpoint() override { int3(); }
void Breakpoint() { int3(); }
void Stop(const char* message) override;

static void InitializeMemoryWithBreakpoints(uword data, intptr_t length);
Expand Down

0 comments on commit e27ceb5

Please sign in to comment.