Skip to content

Commit

Permalink
[Remarks] Remove references to ELF support
Browse files Browse the repository at this point in the history
There is no ELF support at the moment.

Remove all the references to the `.remarks` section.
  • Loading branch information
francisvm committed Oct 28, 2019
1 parent 209d5a1 commit c7557dd
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 13 deletions.
4 changes: 2 additions & 2 deletions llvm/docs/CommandGuide/llc.rst
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,8 @@ End-user Options

.. option:: -remarks-section

Emit the .remarks (ELF) / __remarks (MachO) section which contains metadata
about remark diagnostics.
Emit the __remarks (MachO) section which contains metadata about remark
diagnostics.

Tuning/Configuration Options
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Expand Down
1 change: 0 additions & 1 deletion llvm/docs/Remarks.rst
Original file line number Diff line number Diff line change
Expand Up @@ -592,7 +592,6 @@ This can be overridden by using the flag ``-remarks-section=<bool>``.
The section is named:

* ``__LLVM,__remarks`` (MachO)
* ``.remarks`` (ELF)

C API
=====
Expand Down
2 changes: 1 addition & 1 deletion llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1380,7 +1380,7 @@ void AsmPrinter::emitRemarksSection(RemarkStreamer &RS) {
: RemarkSerializer.metaSerializer(OS);
MetaSerializer->emit();

// Switch to the right section: .remarks/__remarks.
// Switch to the remarks section.
MCSection *RemarksSection =
OutContext.getObjectFileInfo()->getRemarksSection();
OutStreamer->SwitchSection(RemarksSection);
Expand Down
3 changes: 0 additions & 3 deletions llvm/lib/MC/MCObjectFileInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -480,9 +480,6 @@ void MCObjectFileInfo::initELFMCObjectFileInfo(const Triple &T, bool Large) {
Ctx->getELFSection(".eh_frame", EHSectionType, EHSectionFlags);

StackSizesSection = Ctx->getELFSection(".stack_sizes", ELF::SHT_PROGBITS, 0);

RemarksSection =
Ctx->getELFSection(".remarks", ELF::SHT_PROGBITS, ELF::SHF_EXCLUDE);
}

void MCObjectFileInfo::initCOFFMCObjectFileInfo(const Triple &T) {
Expand Down
6 changes: 0 additions & 6 deletions llvm/test/CodeGen/X86/remarks-section.ll
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
; RUN: llc < %s -mtriple=x86_64-linux -remarks-section -pass-remarks-output=%/t.yaml | FileCheck -DPATH=%/t.yaml %s
; RUN: llc < %s -mtriple=x86_64-darwin -remarks-section -pass-remarks-output=%/t.yaml | FileCheck --check-prefix=CHECK-DARWIN -DPATH=%/t.yaml %s
; RUN: llc < %s -mtriple=x86_64-darwin --pass-remarks-format=yaml-strtab -remarks-section -pass-remarks-output=%/t.yaml | FileCheck --check-prefix=CHECK-DARWIN-STRTAB -DPATH=%/t.yaml %s

Expand All @@ -8,11 +7,6 @@
; RUN: llc < %s -mtriple=x86_64-darwin --pass-remarks-format=bitstream -remarks-section=false -pass-remarks-output=%/t.yaml | FileCheck --check-prefix=CHECK-DARWIN-OVERRIDE-BITSTREAM %s
; RUN: llc < %s -mtriple=x86_64-darwin --pass-remarks-format=yaml -remarks-section=true -pass-remarks-output=%/t.yaml | FileCheck --check-prefix=CHECK-DARWIN-OVERRIDE-YAML %s

; CHECK-LABEL: func1:

; CHECK: .section .remarks,"e",@progbits
; CHECK-NEXT: .byte

; CHECK-DARWIN: .section __LLVM,__remarks,regular,debug
; CHECK-DARWIN-NEXT: .byte

Expand Down

0 comments on commit c7557dd

Please sign in to comment.