Skip to content

Conversation

@PeterYang12
Copy link
Owner

Indirect CALL/JMP must target an ENDBR instruction or suffer #CP when Indirect Branch Tracking (IBT) is enabled.

This commit inserts somes endbr32/64 instructions which are missing in indirect branch target for jitted code.

Signed-off-by: PeterYang12 yuhan.yang@intel.com

@chen-hu-97
Copy link

JIT: add missing endbr

PR php#8774 added IBT support for jited code and passed all built-in tests in
"ext/opcache/tests/jit". However, we found several "missing ENDBR" issues
recently when run some real world workloads.

Such workloads introduce new code path and thus more "indirect branch target"
in jited code. This fix adds missing endbr correspondingly.

PR php#8774 added IBT support for jitted code and passed all built-in tests in
"ext/opcache/tests/jit". However, we found several "missing ENDBR" issues
recently when running some real world workloads.

Such workloads introduce new code path and thus more "indirect branch target"
are in jited code. This fix adds missing endbr correspondingly.

Signed-off-by: PeterYang12 <yuhan.yang@intel.com>
Reviewed-by:   chen-hu-97  <hu1.chen@intel.com>
Reviewed-by:   bjzhjing    <cathy.zhang@intel.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants