[PATCH] D137834: [Support] Reduce Dependence on Host.h
Francesco Petrogalli via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Nov 17 02:34:06 PST 2022
fpetrogalli accepted this revision.
fpetrogalli added a comment.
LGTM. Thank you.
================
Comment at: llvm/lib/Support/SHA256.cpp:246-252
+ // Just copy the current state
+ for (int i = 0; i < 8; i++) {
+ HashResult[i] = InternalState.State[i];
+ }
+ } else {
+ // Swap byte order back
+ for (int i = 0; i < 8; i++) {
----------------
lenary wrote:
> fpetrogalli wrote:
> > Tabs?
> No, I've indented with spaces. The chevrons are in the margin, and are Phabricator's way of showing that for most of these lines, only the indentation changed.
Thank you for explaining.
================
Comment at: llvm/lib/Support/SHA256.cpp:253
+ for (int i = 0; i < 8; i++) {
+ HashResult[i] = sys::getSwappedBytes(InternalState.State[i]);
+ }
----------------
lenary wrote:
> fpetrogalli wrote:
> > This is an improvement that is unrelated to making libSupport less dependent on Host.cpp. I'd suggest to either mention the extra change in the commit message, or factor it out as a separate commit (up to you).
> I'll mention it in the message when I commit this.
SGTM.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D137834/new/
https://reviews.llvm.org/D137834
More information about the llvm-commits
mailing list