Attention is currently required from: Arthur Heymans.
Hello Arthur Heymans,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/80304?usp=email
to look at the new patch set (#3).
Change subject: commonlib: Add generic word-at-a-time optimization to ipchksum()
......................................................................
commonlib: Add generic word-at-a-time optimization to ipchksum()
This patch adds a generic optimization to calculate a machine-word-sized
"wide sum" for the ipchksum() algorithm. This is often not as
efficient as handcrafted assembly (about half as fast on arm64 and
x86_32, about the same speed on x86_64), but likely still much better
than nothing on architectures that we don't have handcrafted assembly
for.
Change-Id: I8f0fe117e2788d1b6801b73824b97e1e31ecc694
Signed-off-by: Julius Werner <jwerner(a)chromium.org>
---
M src/commonlib/bsd/ipchksum.c
1 file changed, 14 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/04/80304/3
--
To view, visit https://review.coreboot.org/c/coreboot/+/80304?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: main
Gerrit-Change-Id: I8f0fe117e2788d1b6801b73824b97e1e31ecc694
Gerrit-Change-Number: 80304
Gerrit-PatchSet: 3
Gerrit-Owner: Julius Werner <jwerner(a)chromium.org>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-CC: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-MessageType: newpatchset
Attention is currently required from: Arthur Heymans.
Hello Arthur Heymans,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/80304?usp=email
to look at the new patch set (#2).
Change subject: commonlib: Add generic word-at-a-time optimization to ipchksum()
......................................................................
commonlib: Add generic word-at-a-time optimization to ipchksum()
This patch adds a generic optimization to calculate a machine-word-sized
"wide sum" for the ipchksum() algorithm. This is often not as
efficient as handcrafted assembly (about half as fast on arm64 and
x86_32, about the same speed on x86_64), but likely still much better
than nothing on architectures that we don't have handcrafted assembly
for.
Change-Id: I8f0fe117e2788d1b6801b73824b97e1e31ecc694
Signed-off-by: Julius Werner <jwerner(a)chromium.org>
---
M src/commonlib/bsd/ipchksum.c
1 file changed, 13 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/04/80304/2
--
To view, visit https://review.coreboot.org/c/coreboot/+/80304?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: main
Gerrit-Change-Id: I8f0fe117e2788d1b6801b73824b97e1e31ecc694
Gerrit-Change-Number: 80304
Gerrit-PatchSet: 2
Gerrit-Owner: Julius Werner <jwerner(a)chromium.org>
Gerrit-Reviewer: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-Attention: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-MessageType: newpatchset
Julius Werner has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/80304?usp=email )
Change subject: commonlib: Add generic word-at-a-time optimization to ipchksum()
......................................................................
commonlib: Add generic word-at-a-time optimization to ipchksum()
This patch adds a generic optimization to calculate a machine-word-sized
"wide sum" for the ipchksum() algorithm. This is often not as
efficient as handcrafted assembly (about half as fast on arm64 and
x86_32, about the same speed on x86_64), but likely still much better
than nothing on architectures that we don't have handcrafted assembly
for.
Change-Id: I8f0fe117e2788d1b6801b73824b97e1e31ecc694
Signed-off-by: Julius Werner <jwerner(a)chromium.org>
---
M src/commonlib/bsd/ipchksum.c
1 file changed, 13 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/04/80304/1
diff --git a/src/commonlib/bsd/ipchksum.c b/src/commonlib/bsd/ipchksum.c
index b7434e5..8e0aa9b 100644
--- a/src/commonlib/bsd/ipchksum.c
+++ b/src/commonlib/bsd/ipchksum.c
@@ -34,7 +34,7 @@
:: "cc"
);
}
-#elif defined(__i386__) || defined(__x86_64__)
+#elif defined(__i386__) || defined(__x86_64__) /* __aarch64__ */
size_t size8 = size / 8;
const uint64_t *p8 = data;
i = size8 * 8;
@@ -57,7 +57,18 @@
[size8] "+c" (size8) /* put size in ECX so we can JECXZ */
:: "cc"
);
-#endif /* __i386__ || __x86_64__ */
+#else /* __i386__ || __x86_64__ */
+ size_t aligned_size = ALIGN_DOWN(size, sizeof(unsigned long));
+ const unsigned long *p_long = data;
+ for (; i < aligned_size; i += sizeof(unsigned long)) {
+ unsigned long new = wide_sum + *p_long++;
+ /* Overflow check to emulate a manual "add with carry" in C. The compiler seems
+ to be clever enough to find ways to elide the branch on most archs. */
+ if (new < wide_sum)
+ new++;
+ wide_sum = new;
+ }
+#endif
while (wide_sum) {
sum += wide_sum & 0xFFFF;
--
To view, visit https://review.coreboot.org/c/coreboot/+/80304?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: main
Gerrit-Change-Id: I8f0fe117e2788d1b6801b73824b97e1e31ecc694
Gerrit-Change-Number: 80304
Gerrit-PatchSet: 1
Gerrit-Owner: Julius Werner <jwerner(a)chromium.org>
Gerrit-MessageType: newchange
Attention is currently required from: Felix Held, Fred Reitberger, Jason Glenesk.
Matt DeVillier has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/80298?usp=email )
Change subject: soc/amd/phoenix/chip.h: guard FSP-specific data structures
......................................................................
Patch Set 2: Code-Review+2
--
To view, visit https://review.coreboot.org/c/coreboot/+/80298?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: main
Gerrit-Change-Id: I6c324421fbc3dc7b9a7bf6f5868785e9718147a5
Gerrit-Change-Number: 80298
Gerrit-PatchSet: 2
Gerrit-Owner: Felix Held <felix-coreboot(a)felixheld.de>
Gerrit-Reviewer: Fred Reitberger <reitbergerfred(a)gmail.com>
Gerrit-Reviewer: Jason Glenesk <jason.glenesk(a)gmail.com>
Gerrit-Reviewer: Matt DeVillier <matt.devillier(a)amd.corp-partner.google.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Jason Glenesk <jason.glenesk(a)gmail.com>
Gerrit-Attention: Fred Reitberger <reitbergerfred(a)gmail.com>
Gerrit-Attention: Felix Held <felix-coreboot(a)felixheld.de>
Gerrit-Comment-Date: Thu, 01 Feb 2024 23:17:07 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: Felix Held, Fred Reitberger, Jason Glenesk.
Matt DeVillier has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/80297?usp=email )
Change subject: soc/amd/phoenix/fch: only init ACPI IO ports in FSP case
......................................................................
Patch Set 1: Code-Review+2
(1 comment)
Commit Message:
https://review.coreboot.org/c/coreboot/+/80297/comment/91ef2d57_808367f6 :
PS1, Line 9: don't overwrite
: those by the coreboot code.
phrasing is slightly awkward, maybe "coreboot should not overwrite them"
--
To view, visit https://review.coreboot.org/c/coreboot/+/80297?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: main
Gerrit-Change-Id: If10e5a9f52ab313ad1afebd7f9e722994d48b0a7
Gerrit-Change-Number: 80297
Gerrit-PatchSet: 1
Gerrit-Owner: Felix Held <felix-coreboot(a)felixheld.de>
Gerrit-Reviewer: Fred Reitberger <reitbergerfred(a)gmail.com>
Gerrit-Reviewer: Jason Glenesk <jason.glenesk(a)gmail.com>
Gerrit-Reviewer: Matt DeVillier <matt.devillier(a)amd.corp-partner.google.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Jason Glenesk <jason.glenesk(a)gmail.com>
Gerrit-Attention: Fred Reitberger <reitbergerfred(a)gmail.com>
Gerrit-Attention: Felix Held <felix-coreboot(a)felixheld.de>
Gerrit-Comment-Date: Thu, 01 Feb 2024 23:16:48 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: Felix Held, Fred Reitberger, Jason Glenesk.
Matt DeVillier has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/80296?usp=email )
Change subject: soc/amd/phoenix: add openSIL calls
......................................................................
Patch Set 1: Code-Review+2
--
To view, visit https://review.coreboot.org/c/coreboot/+/80296?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: main
Gerrit-Change-Id: I6f37bf211e130cb44927f8a0e7f9134d246dfc1c
Gerrit-Change-Number: 80296
Gerrit-PatchSet: 1
Gerrit-Owner: Felix Held <felix-coreboot(a)felixheld.de>
Gerrit-Reviewer: Fred Reitberger <reitbergerfred(a)gmail.com>
Gerrit-Reviewer: Jason Glenesk <jason.glenesk(a)gmail.com>
Gerrit-Reviewer: Matt DeVillier <matt.devillier(a)amd.corp-partner.google.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Jason Glenesk <jason.glenesk(a)gmail.com>
Gerrit-Attention: Fred Reitberger <reitbergerfred(a)gmail.com>
Gerrit-Attention: Felix Held <felix-coreboot(a)felixheld.de>
Gerrit-Comment-Date: Thu, 01 Feb 2024 23:15:20 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment
Attention is currently required from: Felix Held, Fred Reitberger, Jason Glenesk.
Matt DeVillier has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/80294?usp=email )
Change subject: soc/amd/phoenix: add get_pci_routing_table stub for non-FSP case
......................................................................
Patch Set 1: Code-Review+2
--
To view, visit https://review.coreboot.org/c/coreboot/+/80294?usp=email
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: main
Gerrit-Change-Id: I5003e287d6a3a9320922beaffff8a3a846531e14
Gerrit-Change-Number: 80294
Gerrit-PatchSet: 1
Gerrit-Owner: Felix Held <felix-coreboot(a)felixheld.de>
Gerrit-Reviewer: Fred Reitberger <reitbergerfred(a)gmail.com>
Gerrit-Reviewer: Jason Glenesk <jason.glenesk(a)gmail.com>
Gerrit-Reviewer: Matt DeVillier <matt.devillier(a)amd.corp-partner.google.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply(a)coreboot.org>
Gerrit-Attention: Jason Glenesk <jason.glenesk(a)gmail.com>
Gerrit-Attention: Fred Reitberger <reitbergerfred(a)gmail.com>
Gerrit-Attention: Felix Held <felix-coreboot(a)felixheld.de>
Gerrit-Comment-Date: Thu, 01 Feb 2024 23:14:46 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: Yes
Gerrit-MessageType: comment