[PATCH] D78680: [flang] Compute sizes and offsets for symbols

Tim Keith via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 23 13:34:11 PDT 2020


tskeith marked an inline comment as done.
tskeith added inline comments.


================
Comment at: flang/lib/Semantics/compute-offsets.cpp:76
+  }
+  // NOTE: these must be sorted in the same order as in .mod files
+  std::sort(sorted.begin(), sorted.end(),
----------------
sscalpone wrote:
> Please say why the sort must be the same.  Is there a way to assert that sizing and alignment match the mod file?
I've changed it so that both places get the symbol list the same way, so it's guaranteed to be in the same order.

I suppose that a test we could do is compile the .mod file and verify we get the same sizes and offsets as when compiling the original file.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D78680/new/

https://reviews.llvm.org/D78680





More information about the llvm-commits mailing list