Commit e5ea57a5 authored by Hao Xu's avatar Hao Xu Committed by Commit Bot

Mark builtins as hot sections using text section prefix in Windows.

This will places builtins in .text$hot code section that is generated by native compiler PGO

Change-Id: I9e66eea99fc9b25cda9d9a9d1f57a0cd43d3a924
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2628595
Commit-Queue: Jakob Gruber <jgruber@chromium.org>
Reviewed-by: 's avatarJakob Gruber <jgruber@chromium.org>
Cr-Commit-Position: refs/heads/master@{#72213}
parent 21541676
...@@ -566,8 +566,15 @@ int PlatformEmbeddedFileWriterWin::IndentedDataDirective( ...@@ -566,8 +566,15 @@ int PlatformEmbeddedFileWriterWin::IndentedDataDirective(
#else #else
// The directives for text section prefix come from the COFF
// (Common Object File Format) standards:
// https://llvm.org/docs/Extensions.html
//
// .text$hot means this section contains hot code.
// x means executable section.
// r means read-only section.
void PlatformEmbeddedFileWriterWin::SectionText() { void PlatformEmbeddedFileWriterWin::SectionText() {
fprintf(fp_, ".section .text\n"); fprintf(fp_, ".section .text$hot,\"xr\"\n");
} }
void PlatformEmbeddedFileWriterWin::SectionData() { void PlatformEmbeddedFileWriterWin::SectionData() {
......
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