Index: lib/Target/X86/X86PfmCounters.td =================================================================== --- lib/Target/X86/X86PfmCounters.td +++ lib/Target/X86/X86PfmCounters.td @@ -20,6 +20,7 @@ "uops_dispatched_port:port_3"]>; def SBPort4Counter : PfmIssueCounter; def SBPort5Counter : PfmIssueCounter; +def SBUopsCounter : PfmUopsCounter<"uops_issued:any">; } let SchedModel = HaswellModel in { @@ -45,6 +46,7 @@ def BWPort5Counter : PfmIssueCounter; def BWPort6Counter : PfmIssueCounter; def BWPort7Counter : PfmIssueCounter; +def BWUopsCounter : PfmUopsCounter<"uops_issued:any">; } let SchedModel = SkylakeClientModel in { @@ -69,6 +71,7 @@ def SKXPort5Counter : PfmIssueCounter; def SKXPort6Counter : PfmIssueCounter; def SKXPort7Counter : PfmIssueCounter; +def SKXUopsCounter : PfmUopsCounter<"uops_issued:any">; } let SchedModel = BtVer2Model in { Index: lib/Target/X86/X86SchedBroadwell.td =================================================================== --- lib/Target/X86/X86SchedBroadwell.td +++ lib/Target/X86/X86SchedBroadwell.td @@ -1373,10 +1373,10 @@ } def: InstRW<[BWWriteResGroup153], (instrs CMPXCHG8B)>; -def BWWriteResGroup154 : SchedWriteRes<[BWPort5]> { - let Latency = 16; - let NumMicroOps = 16; - let ResourceCycles = [16]; +def BWWriteResGroup154 : SchedWriteRes<[BWPort5,BWPort6]> { + let Latency = 8; + let NumMicroOps = 20; + let ResourceCycles = [1,1]; } def: InstRW<[BWWriteResGroup154], (instrs VZEROALL)>; Index: lib/Target/X86/X86SchedHaswell.td =================================================================== --- lib/Target/X86/X86SchedHaswell.td +++ lib/Target/X86/X86SchedHaswell.td @@ -1616,10 +1616,10 @@ } def: InstRW<[HWWriteResGroup144], (instrs INSB, INSL, INSW)>; -def HWWriteResGroup145 : SchedWriteRes<[HWPort5]> { - let Latency = 16; - let NumMicroOps = 16; - let ResourceCycles = [16]; +def HWWriteResGroup145 : SchedWriteRes<[HWPort5, HWPort6]> { + let Latency = 8; + let NumMicroOps = 20; + let ResourceCycles = [1,1]; } def: InstRW<[HWWriteResGroup145], (instrs VZEROALL)>; Index: lib/Target/X86/X86SchedSandyBridge.td =================================================================== --- lib/Target/X86/X86SchedSandyBridge.td +++ lib/Target/X86/X86SchedSandyBridge.td @@ -1103,6 +1103,13 @@ } def: InstRW<[SBWriteResGroup131], (instregex "DIV(R?)_FI(16|32)m")>; +def SBWriteResGroupVzeroall : SchedWriteRes<[SBPort5]> { + let Latency = 9; + let NumMicroOps = 20; + let ResourceCycles = [2]; +} +def: InstRW<[SBWriteResGroupVzeroall], (instrs VZEROALL)>; + def: InstRW<[WriteZero], (instrs CLC)>; // Intruction variants handled by the renamer. These might not need execution Index: lib/Target/X86/X86SchedSkylakeServer.td =================================================================== --- lib/Target/X86/X86SchedSkylakeServer.td +++ lib/Target/X86/X86SchedSkylakeServer.td @@ -2085,10 +2085,10 @@ } def: InstRW<[SKXWriteResGroup199], (instrs CMPXCHG8B)>; -def SKXWriteResGroup200 : SchedWriteRes<[SKXPort0156]> { - let Latency = 16; - let NumMicroOps = 16; - let ResourceCycles = [16]; +def SKXWriteResGroup200 : SchedWriteRes<[SKXPort1, SKXPort05, SKXPort6]> { + let Latency = 12; + let NumMicroOps = 34; + let ResourceCycles = [1, 4, 5]; } def: InstRW<[SKXWriteResGroup200], (instrs VZEROALL)>;