arm64: defconfig: enable CONFIG_SCHED_CLUSTER
PATCH 1/1 arm64: defconfig: enable CONFIG_SCHED_CLUSTER
In the server, if some workload which will create lot of tasks, and will have many task migrations, we can get better performance when we enable the CONFIG_SCHED_CLUSTER.
For example, the Specjbb may have better performance:
Critical-jops : 26%
Max-jops : 7%
So enable it by default.
--- arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+)
arch/arm64/configs/defconfig +1 -0
@@ -82,6 +82,7 @@ CONFIG_ARCH_VISCONTI=y CONFIG_ARCH_XGENE=y CONFIG_ARCH_ZYNQMP=y CONFIG_SCHED_MC=y +CONFIG_SCHED_CLUSTER=y CONFIG_SCHED_SMT=y CONFIG_NUMA=y CONFIG_XEN=y
Signature · 1 line
2.40.1
Hi,
Quoted 9 lines · Huang Shijie
In the server, if some workload which will create lot of tasks, and will have many task migrations, we can get better performance when we enable the
CONFIG_SCHED_CLUSTER.For example, the Specjbb may have better performance:
Critical-jops : 26%
Max-jops : 7%So enable it by default.
From what I've seen, SCHED_CLUSTER seems to be a bit of give and take depending on benchmark and machine. I'm not sure if it should be default enabled or not, but it would really be nice to have at least a larger sweep of benchmarks/machines in order to be sure of the decision.
Thanks,
Quoted 19 lines
Reviewed-by Christoph Lameter (Ampere) <[email protected]>Signed-off-by Huang Shijie <[email protected]>--- arch/arm64/configs/defconfig | 1 + 1 file changed, 1 insertion(+)arch/arm64/configs/defconfig +1
-0@@ -82,6 +82,7 @@ CONFIG_ARCH_VISCONTI=y CONFIG_ARCH_XGENE=y CONFIG_ARCH_ZYNQMP=y CONFIG_SCHED_MC=y +CONFIG_SCHED_CLUSTER=y CONFIG_SCHED_SMT=y CONFIG_NUMA=y CONFIG_XEN=y
Quoted 7 lines · Jeremy Linton
Hi,
Quoted 4 lines · Huang Shijie
In the server, if some workload which will create lot of tasks, and will have many task migrations, we can get better performance when we enable the
CONFIG_SCHED_CLUSTER.
Quoted 7 lines
Quoted 5 lines
For example, the Specjbb may have better performance:
Critical-jops : 26%
Max-jops : 7%So enable it by default.
From what I've seen,
SCHED_CLUSTERseems to be a bit of give and take depending on benchmark and machine. I'm not sure if it should be default enabled or not, but it would really be nice to have at least a larger sweep of benchmarks/machines in order to be sure of the decision.
Yes, I agree.
Maybe I should create a patch only enable SCHED_CLUSTER for Ampere's machine.
Thanks
Quoted 2 lines
Quoted 4 lines · Jeremy Linton
From what I've seen,
SCHED_CLUSTERseems to be a bit of give and take depending on benchmark and machine. I'm not sure if it should be default enabled or not, but it would really be nice to have at least a larger sweep of benchmarks/machines in order to be sure of the decision.
If the hardware provides a clusterid then I think this clusterid should be used for the sched domains. CONFIG_SCHED_CLUSTER does that. So it should be the default.
If there is no cluster information then these domains should not be created. I think that is already the case?
Quoted 10 lines · Christoph Lameter (Ampere)
Quoted 4 lines · Jeremy Linton
From what I've seen,
SCHED_CLUSTERseems to be a bit of give and take
depending on benchmark and machine. I'm not sure if it should be default enabled or not, but it would really be nice to have at least a larger sweep of benchmarks/machines in order to be sure of the decision.If the hardware provides a clusterid then I think this clusterid should be used for the sched domains.
CONFIG_SCHED_CLUSTERdoes that. So it should be the default.
Hi,
The problem is that this information is being sourced from the ACPI PPTT. The ACPI specification (AFAIK) doesn't define a cluster, so the linux cluster information is being 'invented' based on however the firmware vendor choose to group CPU nodes in the PPTT. Which means its possible for them to unknowingly create clusters, or also fail to create them when they make sense.
Quoted 5 lines
If there is no cluster information then these domains should not be created. I think that is already the case?
Quoted 12 lines · Jeremy Linton
Quoted 10 lines · Christoph Lameter (Ampere)
Quoted 4 lines · Jeremy Linton
From what I've seen,
SCHED_CLUSTERseems to be a bit of give and take
depending on benchmark and machine. I'm not sure if it should be default enabled or not, but it would really be nice to have at least a larger sweep of benchmarks/machines in order to be sure of the decision.If the hardware provides a clusterid then I think this clusterid should be used for the sched domains.
CONFIG_SCHED_CLUSTERdoes that. So it should be the default.
Quoted 8 lines
Hi,
The problem is that this information is being sourced from the ACPI PPTT. The ACPI specification (AFAIK) doesn't define a cluster, so the linux cluster information is being 'invented' based on however the firmware vendor choose to group CPU nodes in the PPTT. Which means its possible for them to unknowingly create clusters, or also fail to create them when they make sense.
+1, completely agree. As Jeremy mentioned, it is hit or miss and cluster is loosely defined and IIRC Huawei pushed this based on their platform at the time and it did break some benchmarks on few other platforms. So it is not a good idea to make it default config IMO.
Signature · 2 lines
Regards, Sudeep
Quoted 11 lines · Sudeep Holla
Quoted 6 lines
The problem is that this information is being sourced from the ACPI PPTT. The ACPI specification (AFAIK) doesn't define a cluster, so the linux cluster information is being 'invented' based on however the firmware vendor choose to group CPU nodes in the PPTT. Which means its possible for them to unknowingly create clusters, or also fail to create them when they make sense.
+1, completely agree. As Jeremy mentioned, it is hit or miss and cluster is loosely defined and IIRC Huawei pushed this based on their platform at the time and it did break some benchmarks on few other platforms. So it is not a good idea to make it default config IMO.
Can we figure out which platforms benchmarks were affected and why?
It seems the notion of a "cluster" on ARM64 is derived (I guess a better word than "invented" hehe) from sibling information instead of PPTT. But using that information should work fine right?
Quoted 5 lines · Christoph Lameter (Ampere)
Can we figure out which platforms benchmarks were affected and why?
It seems the notion of a "cluster" on ARM64 is derived (I guess a better word than "invented" hehe) from sibling information instead of PPTT. But using that information should work fine right?
Sorry no that is not correct. The cluster information is correctly read from the ACPI tables and the cluster ids are avaialble in
/sys/devices/system/cpu/cpuXX/topology/cluster_id
if CONFIG_SCHED_CLUSTER is enabled.
If there is an issue then it is a problem with the vendor firmware providing cluster id configurations via ACPI that cause regressions.
We could add a blacklist for those platforms to avoid regressions but we should not allow that to hinder us to enable full support for clustering on ARM64.
Quoted 4 lines · Christoph Lameter (Ampere)
Quoted 2 lines · Christoph Lameter (Ampere)
Can we figure out which platforms benchmarks were affected and why?
Quoted 9 lines
Quoted 3 lines
It seems the notion of a "cluster" on ARM64 is derived (I guess a better word than "invented" hehe) from sibling information instead of PPTT. But using that information should work fine right?
Sorry no that is not correct. The cluster information is correctly read from the ACPI tables and the cluster ids are avaialble in
/sys/devices/system/cpu/cpuXX/topology/cluster_id
Agreed, the parts of ACPI specification has added notion of cluster sprinkle across various chapters(mostly added by Arm in the earlier days though the Arm architecture specification itself doesn't have any standard definition for the cluster). Also note it nicely adds a disclaimer:
| Different architectures use different terminology to denominate logically | associated processors, but terms such as package, cluster, module, and | socket are typical examples.
So how can one use these across architectures ? Package/Socket is quite standard. Cluster can be group of processors or it can also be group of processor clusters. One of the Arm vendors call it super cluster or something. All these makes it super hard for a generic OS to interpret that information. Just CONFIG_SCHED_CLUSTER was added with one notion of cluster which was soon realised doesn't match with some other notion of it.
We can enable it and I am sure someone will report a regression on their platform and we need to disable it again. The benchmark doesn't purely depend on just the "notion" of cluster but it is often related to the private resource and how they are shared in the system. So even if you strictly follow the notion of cluster as supported by CONFIG_SCHED_CLUSTER it will fail on systems where the private resources are shared across the "cluster" boundaries or some variant configuration.
Quoted 5 lines
if
CONFIG_SCHED_CLUSTERis enabled.If there is an issue then it is a problem with the vendor firmware providing cluster id configurations via ACPI that cause regressions.
As mentioned, it is not strictly just the cluster id but other shared resources that contribute to the issues/regressions.
Quoted 4 lines
We could add a blacklist for those platforms to avoid regressions but we should not allow that to hinder us to enable full support for clustering on ARM64.
Sure, but we need to improve the "cluster" definition in the ACPI and Arm specification, get an agreement on what it means for other architecture first IMO. We don't want to revisit the same topic again without these as IIRC this is the second time we are discussion around this topic.
Signature · 2 lines
Regards, Sudeep
Quoted 10 lines · Sudeep Holla
| Different architectures use different terminology to denominate logically | associated processors, but terms such as package, cluster, module, and | socket are typical examples.So how can one use these across architectures ? Package/Socket is quite standard. Cluster can be group of processors or it can also be group of processor clusters. One of the Arm vendors call it super cluster or something. All these makes it super hard for a generic OS to interpret that information. Just
CONFIG_SCHED_CLUSTERwas added with one notion of cluster which was soon realised doesn't match with some other notion of it.
What the cluster actually is used for is up to the hardware. The linux scheduler provides this functionality. How and when this feature is used by firmware is a vendor issue. There was never a clear definition.
Quoted 7 lines
We can enable it and I am sure someone will report a regression on their platform and we need to disable it again. The benchmark doesn't purely depend on just the "notion" of cluster but it is often related to the private resource and how they are shared in the system. So even if you strictly follow the notion of cluster as supported by
CONFIG_SCHED_CLUSTERit will fail on systems where the private resources are shared across the "cluster" boundaries or some variant configuration.
That is not our problem. If the vendor provides clustering information and the scheduler uses that then the vendor can modify the firmware to not enable clustering.
As mentioned before: We could create a blacklist to override the ACPI info from the vendor to ensure that clustering is off.
What we should not do is disabling clustering for all.
Quoted 9 lines
Quoted 4 lines
We could add a blacklist for those platforms to avoid regressions but we should not allow that to hinder us to enable full support for clustering on ARM64.
Sure, but we need to improve the "cluster" definition in the ACPI and Arm specification, get an agreement on what it means for other architecture first IMO. We don't want to revisit the same topic again without these as IIRC this is the second time we are discussion around this topic.
The vendors need flexibility to use this feature when it makes sense.
Having a clear definition would limit the use of clustering feature and limits innovation. Vendors can control the clustering via ACPI and the firmware they provide with their system.
We could change definition but that but that would be a decadelong process which will encounter resistance from vendors that make uses of the clustering feature that does not fall into the stricter definition.
Quoted 13 lines · Christoph Lameter (Ampere)
Quoted 10 lines · Sudeep Holla
| Different architectures use different terminology to denominate logically | associated processors, but terms such as package, cluster, module, and | socket are typical examples.So how can one use these across architectures ? Package/Socket is quite standard. Cluster can be group of processors or it can also be group of processor clusters. One of the Arm vendors call it super cluster or something. All these makes it super hard for a generic OS to interpret that information. Just
CONFIG_SCHED_CLUSTERwas added with one notion of cluster which was soon realised doesn't match with some other notion of it.
Quoted 4 lines
What the cluster actually is used for is up to the hardware. The linux scheduler provides this functionality. How and when this feature is used by firmware is a vendor issue. There was never a clear definition.
Sure, since it is left to architecture to define what it means, it could work. But what happens if we have multiple chiplet inside a socket and each chiplet has multiple cluster. Do you envision using this SCHED_CLUSTER at chiplet level if that works best on the platform ?
That could work, but we need to document all these with the best of our knowledge now so that it is easy to revisit in the future.
Quoted 8 lines
Quoted 7 lines
We can enable it and I am sure someone will report a regression on their platform and we need to disable it again. The benchmark doesn't purely depend on just the "notion" of cluster but it is often related to the private resource and how they are shared in the system. So even if you strictly follow the notion of cluster as supported by
CONFIG_SCHED_CLUSTERit will fail on systems where the private resources are shared across the "cluster" boundaries or some variant configuration.
Quoted 4 lines
That is not our problem. If the vendor provides clustering information and the scheduler uses that then the vendor can modify the firmware to not enable clustering.
That is pure wrong. ACPI is describing the hardware. Deciding to put clustering information in these tables only if it provides performance or not hinder performance seem complete non-sense to me. That covering policy in ACPI hardware description. Does ACPI spec mention anything about it ? I mean remove some hardware description even if it is 100% accurate if it hinders performance on one of the OSPM ? Doesn't sound correct at all.
Quoted 3 lines
As mentioned before: We could create a blacklist to override the ACPI info from the vendor to ensure that clustering is off.
Not a bad idea. We can see if allow or blocklist works as we start with one.
Quoted 2 lines
What we should not do is disabling clustering for all.
Not completely against it but I have concerns on how all these scale with multiple chiplets within a socket or any such variants.
Quoted 5 lines
Quoted 5 lines
Quoted 4 lines
We could add a blacklist for those platforms to avoid regressions but we should not allow that to hinder us to enable full support for clustering on ARM64.
Quoted 7 lines
Quoted 4 lines
Sure, but we need to improve the "cluster" definition in the ACPI and Arm specification, get an agreement on what it means for other architecture first IMO. We don't want to revisit the same topic again without these as IIRC this is the second time we are discussion around this topic.
The vendors need flexibility to use this feature when it makes sense.
Sure, but too much flexibility might also hinder future changes when adding some other feature(chiplet again is one thing I can think of now)
Quoted 4 lines
Having a clear definition would limit the use of clustering feature and limits innovation. Vendors can control the clustering via ACPI and the firmware they provide with their system.
Not sure if that should be right direction TBH, but again not against the idea of enabling the feature on some platforms if we are going to enable it by default.
Quoted 4 lines
We could change definition but that but that would be a decadelong process which will encounter resistance from vendors that make uses of the clustering feature that does not fall into the stricter definition.
I understand and get the point, but decadelong is bit of an exaggeration 😉. Not discussing these in ACPI or similar forum is not a good idea as we know there are new h/w features that are being added and current specification may not provide ways to express all of those.
Signature · 2 lines
Regards, Sudeep
Hi,
Quoted 47 lines · Sudeep Holla
Quoted 13 lines · Christoph Lameter (Ampere)
Quoted 10 lines · Sudeep Holla
| Different architectures use different terminology to denominate logically | associated processors, but terms such as package, cluster, module, and | socket are typical examples.So how can one use these across architectures ? Package/Socket is quite standard. Cluster can be group of processors or it can also be group of processor clusters. One of the Arm vendors call it super cluster or something. All these makes it super hard for a generic OS to interpret that information. Just
CONFIG_SCHED_CLUSTERwas added with one notion of cluster which was soon realised doesn't match with some other notion of it.Quoted 4 lines
What the cluster actually is used for is up to the hardware. The linux scheduler provides this functionality. How and when this feature is used by firmware is a vendor issue. There was never a clear definition.
Sure, since it is left to architecture to define what it means, it could work. But what happens if we have multiple chiplet inside a socket and each chiplet has multiple cluster. Do you envision using this
SCHED_CLUSTERat chiplet level if that works best on the platform ?That could work, but we need to document all these with the best of our knowledge now so that it is easy to revisit in the future.
Quoted 8 lines
Quoted 7 lines
We can enable it and I am sure someone will report a regression on their platform and we need to disable it again. The benchmark doesn't purely depend on just the "notion" of cluster but it is often related to the private resource and how they are shared in the system. So even if you strictly follow the notion of cluster as supported by
CONFIG_SCHED_CLUSTERit will fail on systems where the private resources are shared across the "cluster" boundaries or some variant configuration.Quoted 4 lines
That is not our problem. If the vendor provides clustering information and the scheduler uses that then the vendor can modify the firmware to not enable clustering.
That is pure wrong. ACPI is describing the hardware. Deciding to put clustering information in these tables only if it provides performance or not hinder performance seem complete non-sense to me. That covering policy in ACPI hardware description. Does ACPI spec mention anything about it ? I mean remove some hardware description even if it is 100% accurate if it hinders performance on one of the OSPM ? Doesn't sound correct at all.
Quoted 5 lines
Quoted 3 lines
As mentioned before: We could create a blacklist to override the ACPI info from the vendor to ensure that clustering is off.
Not a bad idea. We can see if allow or blocklist works as we start with one.
From a distro perspective it makes more sense to me to change it from a compile time option to a runtime kernel command line option with the default on/off set by this SCHED_CLUSTER flag rather than try to maintain a blocklist.
I agree the firmware needs a much clearer way to signal that these nodes represent something other than just side effects of the way the table is built. If the working group is hesitant to declare additional topological flags, maybe this idea of deriving additional topological information from nodes without caches is a reasonable spec clarification. That way some future NODE_IS_A_CLUSTER/DSU/CHIPLET/SUPERCLUSTER/RING/SLICE/WHATEVER doesn't turn the existing code into technical debt.
But returning to the original point, its not clear to me that the HW 'cluster' information is really causing the performance boost vs, just having a medium size scheduling domain (aka just picking an arbitrary size 4-16 cores) under MC, or simply 'slicing' a L3 in the PPTT such that the MC domains are smaller, yields the same effect. I've seen a number of cases where 'lying' about the topology yields a better result in a benchmark. This is largely what is happening with these Firmware toggles that move/remove the NUMA domains too. Being able to manually reconfigure some of these scheduling levels at runtime might be useful...
Quoted 42 lines
Quoted 3 lines
What we should not do is disabling clustering for all.
Not completely against it but I have concerns on how all these scale with multiple chiplets within a socket or any such variants.
Quoted 5 lines
Quoted 5 lines
Quoted 4 lines
We could add a blacklist for those platforms to avoid regressions but we should not allow that to hinder us to enable full support for clustering on ARM64.
Quoted 7 lines
Quoted 4 lines
Sure, but we need to improve the "cluster" definition in the ACPI and Arm specification, get an agreement on what it means for other architecture first IMO. We don't want to revisit the same topic again without these as IIRC this is the second time we are discussion around this topic.
The vendors need flexibility to use this feature when it makes sense.
Sure, but too much flexibility might also hinder future changes when adding some other feature(chiplet again is one thing I can think of now)
Quoted 4 lines
Having a clear definition would limit the use of clustering feature and limits innovation. Vendors can control the clustering via ACPI and the firmware they provide with their system.
Not sure if that should be right direction TBH, but again not against the idea of enabling the feature on some platforms if we are going to enable it by default.
Quoted 4 lines
We could change definition but that but that would be a decadelong process which will encounter resistance from vendors that make uses of the clustering feature that does not fall into the stricter definition.
I understand and get the point, but decadelong is bit of an exaggeration 😉. Not discussing these in ACPI or similar forum is not a good idea as we know there are new h/w features that are being added and current specification may not provide ways to express all of those.
Quoted 55 lines · Jeremy Linton
Hi,
Quoted 51 lines · Sudeep Holla
Quoted 13 lines · Christoph Lameter (Ampere)
Quoted 10 lines · Sudeep Holla
| Different architectures use different terminology to denominate logically | associated processors, but terms such as package, cluster, module, and | socket are typical examples.So how can one use these across architectures ? Package/Socket is quite standard. Cluster can be group of processors or it can also be group of processor clusters. One of the Arm vendors call it super cluster or something. All these makes it super hard for a generic OS to interpret that information. Just
CONFIG_SCHED_CLUSTERwas added with one notion of cluster which was soon realised doesn't match with some other notion of it.Quoted 4 lines
What the cluster actually is used for is up to the hardware. The linux scheduler provides this functionality. How and when this feature is used by firmware is a vendor issue. There was never a clear definition.
Sure, since it is left to architecture to define what it means, it could work. But what happens if we have multiple chiplet inside a socket and each chiplet has multiple cluster. Do you envision using this
SCHED_CLUSTERat chiplet level if that works best on the platform ?That could work, but we need to document all these with the best of our knowledge now so that it is easy to revisit in the future.
Quoted 8 lines
Quoted 7 lines
We can enable it and I am sure someone will report a regression on their platform and we need to disable it again. The benchmark doesn't purely depend on just the "notion" of cluster but it is often related to the private resource and how they are shared in the system. So even if you strictly follow the notion of cluster as supported by
CONFIG_SCHED_CLUSTERit will fail on systems where the private resources are shared across the "cluster" boundaries or some variant configuration.Quoted 4 lines
That is not our problem. If the vendor provides clustering information and the scheduler uses that then the vendor can modify the firmware to not enable clustering.
That is pure wrong. ACPI is describing the hardware. Deciding to put clustering information in these tables only if it provides performance or not hinder performance seem complete non-sense to me. That covering policy in ACPI hardware description. Does ACPI spec mention anything about it ? I mean remove some hardware description even if it is 100% accurate if it hinders performance on one of the OSPM ? Doesn't sound correct at all.
Quoted 3 lines
As mentioned before: We could create a blacklist to override the ACPI info from the vendor to ensure that clustering is off.
Quoted 7 lines
Quoted 1 line
Not a bad idea. We can see if allow or blocklist works as we start with one.
From a distro perspective it makes more sense to me to change it from a compile time option to a runtime kernel command line option with the default on/off set by this
SCHED_CLUSTERflag rather than try to maintain a blocklist.
Right, that makes complete sense to me.
Quoted 9 lines
I agree the firmware needs a much clearer way to signal that these nodes represent something other than just side effects of the way the table is built. If the working group is hesitant to declare additional topological flags, maybe this idea of deriving additional topological information from nodes without caches is a reasonable spec clarification. That way some future NODE_IS_A_CLUSTER/DSU/CHIPLET/SUPERCLUSTER/RING/SLICE/WHATEVER doesn't turn the existing code into technical debt.
100% agreed.
Quoted 10 lines
But returning to the original point, its not clear to me that the HW 'cluster' information is really causing the performance boost vs, just having a medium size scheduling domain (aka just picking an arbitrary size 4-16 cores) under MC, or simply 'slicing' a L3 in the PPTT such that the MC domains are smaller, yields the same effect. I've seen a number of cases where 'lying' about the topology yields a better result in a benchmark. This is largely what is happening with these Firmware toggles that move/remove the NUMA domains too. Being able to manually reconfigure some of these scheduling levels at runtime might be useful...
I share your concern and hence completely again representation of any fake data in the ACPI topology just to get improved performance. Yes we have seen that in the past.
Signature · 2 lines
Regards, Sudeep
Quoted 11 lines · Sudeep Holla
Quoted 10 lines
But returning to the original point, its not clear to me that the HW 'cluster' information is really causing the performance boost vs, just having a medium size scheduling domain (aka just picking an arbitrary size 4-16 cores) under MC, or simply 'slicing' a L3 in the PPTT such that the MC domains are smaller, yields the same effect. I've seen a number of cases where 'lying' about the topology yields a better result in a benchmark. This is largely what is happening with these Firmware toggles that move/remove the NUMA domains too. Being able to manually reconfigure some of these scheduling levels at runtime might be useful...
Quoted 3 lines
I share your concern and hence completely again representation of any fake data in the ACPI topology just to get improved performance. Yes we have seen that in the past.
Depends on what you call fake. There are microarchitectural issues regarding the proximity of the processors that the customer may not know about and therefore the data provides by the vendor may be considered "fake". Certainly that is not the case for our processors.
This is a common feature and widely available on other platforms. There is no need to do anything but enable the functionality. Having a special version of ACPI for arm64 or a special handling for arm64 does not make sense.
The ACPI subsystem provides the ability to add blacklists. If a vendor has problems with their firmward providing data that reduces the performance and is unable to fix it othereise then the vendor can use that feature to disable these ACPI features for their platform by submitting a patch.
Please make arm64 work like the other Linux platforms and do not introduce special handling for ARM64.
Quoted 13 lines · Christoph Lameter (Ampere)
Quoted 11 lines · Sudeep Holla
Quoted 10 lines
But returning to the original point, its not clear to me that the HW 'cluster' information is really causing the performance boost vs, just having a medium size scheduling domain (aka just picking an arbitrary size 4-16 cores) under MC, or simply 'slicing' a L3 in the PPTT such that the MC domains are smaller, yields the same effect. I've seen a number of cases where 'lying' about the topology yields a better result in a benchmark. This is largely what is happening with these Firmware toggles that move/remove the NUMA domains too. Being able to manually reconfigure some of these scheduling levels at runtime might be useful...
Quoted 9 lines
Quoted 3 lines
I share your concern and hence completely again representation of any fake data in the ACPI topology just to get improved performance. Yes we have seen that in the past.
Depends on what you call fake. There are microarchitectural issues regarding the proximity of the processors that the customer may not know about and therefore the data provides by the vendor may be considered "fake". Certainly that is not the case for our processors.
Fair enough. We have seen systems with fake data as those data seem to accidentally improve performance.
Quoted 5 lines
This is a common feature and widely available on other platforms. There is no need to do anything but enable the functionality. Having a special version of ACPI for arm64 or a special handling for arm64 does not make sense.
I am not suggesting to make it any special on Arm64, we would never want that unless absolutely needed and this is not one such thing.
Quoted 5 lines
The ACPI subsystem provides the ability to add blacklists. If a vendor has problems with their firmward providing data that reduces the performance and is unable to fix it othereise then the vendor can use that feature to disable these ACPI features for their platform by submitting a patch.
I don't have a strong opinion on that approach. IIUC, maintaining list needs change in the kernel which Jeremy mentioned is not what distro prefer over command line parameter. We can always have a parameter to disable the feature and keep the build config enabled as in this patch. So only platforms that have performance issue by enabling this will have to add the command line parameter(hopefully that works for all)
Quoted 2 lines
Please make arm64 work like the other Linux platforms and do not introduce special handling for ARM64.
Again I am not suggesting that and we never want that.
Signature · 2 lines
Regards, Sudeep
Quoted 43 lines · Suddep Holla
Quoted 6 lines · Christoph Lameter (Ampere)
Quoted 4 lines · Sudeep Holla
Quoted 4 lines
But returning to the original point, its not clear to me that the HW 'cluster' information is really causing the performance boost vs, just having a medium size scheduling domain (aka just picking an arbitrary size 4-16 cores) under MC, or simply 'slicing' a L3 in the PPTT such that the M
C
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
domains are smaller, yields the same effect. I've seen a number of cases where 'lying' about the topology yields a better result in a benchmark. Th
is
Quoted 5 lines
Quoted 5 lines
Quoted 4 lines
is largely what is happening with these Firmware toggles that move/remove the NUMA domains too. Being able to manually reconfigure some of these scheduling levels at runtime might be useful...
Quoted 8 lines
Quoted 3 lines
I share your concern and hence completely again representation of any fake data in the ACPI topology just to get improved performance. Yes we have seen that in the past.
Depends on what you call fake. There are microarchitectural issues regarding the proximity of the processors that the customer may not know about and therefore the data provides by the vendor may be considered "fake". Certainly that is not the case for our processors.
Fair enough. We have seen systems with fake data as those data seem to accidentally improve performance.
Quoted 5 lines
This is a common feature and widely available on other platforms. There is no need to do anything but enable the functionality. Having a special version of ACPI for arm64 or a special handling for arm64 does not make sense.
I am not suggesting to make it any special on Arm64, we would never want that unless absolutely needed and this is not one such thing.
Quoted 5 lines
The ACPI subsystem provides the ability to add blacklists. If a vendor has problems with their firmward providing data that reduces the performance and is unable to fix it othereise then the vendor can use that feature to disable these ACPI features for their platform by submitting a patch.
Quoted 6 lines
I don't have a strong opinion on that approach. IIUC, maintaining list needs change in the kernel which Jeremy mentioned is not what distro prefer over command line parameter. We can always have a parameter to disable the feature and keep the build config enabled as in this patch. So only platforms that have performance issue by enabling this will have to add the command line parameter(hopefully that works for all)
Resurrecting this old thread.
We enable CONFIG_SCHED_CLUSTER by default on Oracle UEK kernels. And, this thread didn't really come to a consensus, but I'm trying to figure out what's the best approach if we want to enable this by default?
Thanks
--
ankur
Quoted 6 lines · Sudeep Holla
Quoted 5 lines
From a distro perspective it makes more sense to me to change it from a
compile time option to a runtime kernel command line option with the default on/off set by thisSCHED_CLUSTERflag rather than try to maintain a blocklist.Right, that makes complete sense to me.
Anyway, Peter is also try to make the SCHED_CLUSTER as default for arm64 platform, please see the email link:
https://patchew.org/linux/[email protected]/[email protected]/
Quoted 7 lines · Shijie Huang
Quoted 5 lines · Sudeep Holla
Quoted 5 lines
From a distro perspective it makes more sense to me to change it from a
compile time option to a runtime kernel command line option with the default on/off set by thisSCHED_CLUSTERflag rather than try to maintain a blocklist.
Quoted 7 lines
Quoted 1 line
Right, that makes complete sense to me.
Anyway, Peter is also try to make the
SCHED_CLUSTERas default for arm64 platform, please see the email link:https://patchew.org/linux/[email protected]/[email protected]/
Yes, I was cc-ed and I am following the discussions.
Signature · 2 lines
Regards, Sudeep
Quoted 9 lines · Christoph Lameter (Ampere)
Quoted 7 lines · Sudeep Holla
Quoted 6 lines
The problem is that this information is being sourced from the ACPI PPTT. The ACPI specification (AFAIK) doesn't define a cluster, so the linux cluster information is being 'invented' based on however the firmware vendor choose to group CPU nodes in the PPTT. Which means its possible for them to unknowingly create clusters, or also fail to create them when they make sense.
Quoted 7 lines
Quoted 4 lines
+1, completely agree. As Jeremy mentioned, it is hit or miss and cluster is loosely defined and IIRC Huawei pushed this based on their platform at the time and it did break some benchmarks on few other platforms. So it is not a good idea to make it default config IMO.
Can we figure out which platforms benchmarks were affected and why?
I am not sure on either. One way to figure out the affected platforms is to merge this change and expect the platform users/maintainers to report.
Quoted 4 lines
It seems the notion of a "cluster" on ARM64 is derived (I guess a better word than "invented" hehe) from sibling information instead of PPTT. But using that information should work fine right?
I have my doubts but I may be wrong. As mentioned in the other email in this thread, "cluster" IMO is ill-defined both in ACPI and Arm architecture which is the root cause for all the issue around it.
Signature · 2 lines
Regards, Sudeep