chore(3p/rr): Upgrade to latest master with Zen workarounds

* bumps to HEAD of master
* include the zen_workaround script in the drv output

Change-Id: I8f5f33a61b9395295c02f3ea5e930a81b3ffa7ac
Reviewed-on: https://cl.tvl.fyi/c/depot/+/1990
Tested-by: BuildkiteCI
Reviewed-by: kanepyork <rikingcoding@gmail.com>
Reviewed-by: glittershark <grfn@gws.fyi>
This commit is contained in:
Vincent Ambo 2020-09-20 19:51:56 +01:00 committed by tazjin
parent e43620659e
commit 4f7bb40a31
2 changed files with 12 additions and 50 deletions

View file

@ -1,47 +0,0 @@
From 7f54898386f39b65fca902a39d39cd4c258960fd Mon Sep 17 00:00:00 2001
From: Vincent Ambo <mail@tazj.in>
Date: Mon, 13 Jul 2020 17:16:22 +0100
Subject: [PATCH] PerfCounters: don't exit on AMD ThreadRipper 3960X
Patch from
https://github.com/mozilla/rr/issues/2034#issuecomment-581769936
It's unclear whether this will actually make it work - the main issue
seems to be that some complex tests are failing, but people are
reporting that the debugger still works for some cases.
---
src/PerfCounters.cc | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/PerfCounters.cc b/src/PerfCounters.cc
index 7da26a51..1ca830a7 100644
--- a/src/PerfCounters.cc
+++ b/src/PerfCounters.cc
@@ -70,6 +70,7 @@ enum CpuMicroarch {
IntelCometlake,
AMDF15R30,
AMDRyzen,
+ AMDRyzen2,
};
/*
@@ -137,6 +138,7 @@ static const PmuConfig pmu_configs[] = {
{ AMDF15R30, "AMD Family 15h Revision 30h", 0xc4, 0xc6, 0, 250,
PMU_TICKS_TAKEN_BRANCHES | PMU_SKIP_INTEL_BUG_CHECK },
{ AMDRyzen, "AMD Ryzen", 0x5100d1, 0, 0, 1000, PMU_TICKS_RCB },
+ { AMDRyzen2, "AMD Ryzen 2", 0xd1, 0, 0x2c, 2000, PMU_TICKS_RCB | PMU_SKIP_INTEL_BUG_CHECK },
};
#define RR_SKID_MAX 1000
@@ -227,6 +229,8 @@ static CpuMicroarch get_cpu_microarch() {
return IntelCometlake;
case 0x30f00:
return AMDF15R30;
+ case 0x30f10: // AMD Ryzen Threadripper 3960X
+ return AMDRyzen2;
case 0x00f10:
if (ext_family == 8) {
if (!Flags::get().suppress_environment_warnings) {
--
2.23.0

View file

@ -1,7 +1,16 @@
{ pkgs, ... }: { pkgs, ... }:
pkgs.originals.rr.overrideAttrs(_: { pkgs.originals.rr.overrideAttrs(_: {
patches = [ src = pkgs.fetchFromGitHub {
./0001-PerfCounters-don-t-exit-on-AMD-ThreadRipper-3960X.patch owner = "mozilla";
]; repo = "rr";
rev = "8fc7d2a09a739fee1883d262501e88613165c1dd";
sha256 = "0avq5lv082z2sasggfn2awnfrh08cr8f0i9iw1dnrcxa6pc3bi9k";
fetchSubmodules = false;
};
# Workaround as documented on https://github.com/mozilla/rr/wiki/Zen
postInstall = ''
cp $src/scripts/zen_workaround.py $out/bin/rr_zen_workaround
'';
}) })