Skip to content

Commit

Permalink
PPC: Fix trampoline pool blocking.
Browse files Browse the repository at this point in the history
Check whether a trampoline pool should be emitted after unblocking.
Otherwise, back-to-back sequences which block the trampoline pool can
cause it to be out of reach.

R=joransiu@ca.ibm.com, jyan@ca.ibm.com, michael_dawson@ca.ibm.com, dstence@us.ibm.com
BUG=

Review URL: https://codereview.chromium.org/1433343002

Cr-Commit-Position: refs/heads/master@{#31945}
  • Loading branch information
mtbrandy authored and Commit bot committed Nov 11, 2015
1 parent 095e6a4 commit 8779afc
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/ppc/assembler-ppc.h
Original file line number Diff line number Diff line change
Expand Up @@ -1310,7 +1310,10 @@ class Assembler : public AssemblerBase {
}

void StartBlockTrampolinePool() { trampoline_pool_blocked_nesting_++; }
void EndBlockTrampolinePool() { trampoline_pool_blocked_nesting_--; }
void EndBlockTrampolinePool() {
int count = --trampoline_pool_blocked_nesting_;
if (count == 0) CheckTrampolinePoolQuick();
}
bool is_trampoline_pool_blocked() const {
return trampoline_pool_blocked_nesting_ > 0;
}
Expand Down

0 comments on commit 8779afc

Please sign in to comment.