[PATCH] D33968: [codeview] use 32-bit integer for RelocOffset in DebugLinesSubsection

Bob Haarman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 8 18:18:42 PDT 2017


This revision was automatically updated to reflect the committed changes.
Closed by commit rL305043: [codeview] use 32-bit integer for RelocOffset in DebugLinesSubsection (authored by inglorion).

Changed prior to commit:
  https://reviews.llvm.org/D33968?vs=101645&id=101986#toc

Repository:
  rL LLVM

https://reviews.llvm.org/D33968

Files:
  llvm/trunk/include/llvm/DebugInfo/CodeView/DebugLinesSubsection.h
  llvm/trunk/lib/DebugInfo/CodeView/DebugLinesSubsection.cpp
  llvm/trunk/test/DebugInfo/PDB/Inputs/debug-subsections.yaml


Index: llvm/trunk/test/DebugInfo/PDB/Inputs/debug-subsections.yaml
===================================================================
--- llvm/trunk/test/DebugInfo/PDB/Inputs/debug-subsections.yaml
+++ llvm/trunk/test/DebugInfo/PDB/Inputs/debug-subsections.yaml
@@ -38,7 +38,7 @@
         - !Lines
           CodeSize:        10
           Flags:           [  ]
-          RelocOffset:     16
+          RelocOffset:     100016
           RelocSegment:    1
           Blocks:
             - FileName:        'd:\src\llvm\test\debuginfo\pdb\inputs\empty.cpp'
Index: llvm/trunk/lib/DebugInfo/CodeView/DebugLinesSubsection.cpp
===================================================================
--- llvm/trunk/lib/DebugInfo/CodeView/DebugLinesSubsection.cpp
+++ llvm/trunk/lib/DebugInfo/CodeView/DebugLinesSubsection.cpp
@@ -145,7 +145,7 @@
 }
 
 void DebugLinesSubsection::setRelocationAddress(uint16_t Segment,
-                                                uint16_t Offset) {
+                                                uint32_t Offset) {
   RelocOffset = Offset;
   RelocSegment = Segment;
 }
Index: llvm/trunk/include/llvm/DebugInfo/CodeView/DebugLinesSubsection.h
===================================================================
--- llvm/trunk/include/llvm/DebugInfo/CodeView/DebugLinesSubsection.h
+++ llvm/trunk/include/llvm/DebugInfo/CodeView/DebugLinesSubsection.h
@@ -122,16 +122,16 @@
   uint32_t calculateSerializedSize() const override;
   Error commit(BinaryStreamWriter &Writer) const override;
 
-  void setRelocationAddress(uint16_t Segment, uint16_t Offset);
+  void setRelocationAddress(uint16_t Segment, uint32_t Offset);
   void setCodeSize(uint32_t Size);
   void setFlags(LineFlags Flags);
 
   bool hasColumnInfo() const;
 
 private:
   DebugChecksumsSubsection &Checksums;
 
-  uint16_t RelocOffset = 0;
+  uint32_t RelocOffset = 0;
   uint16_t RelocSegment = 0;
   uint32_t CodeSize = 0;
   LineFlags Flags = LF_None;


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D33968.101986.patch
Type: text/x-patch
Size: 1954 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170609/6106a70e/attachment.bin>


More information about the llvm-commits mailing list