Intel® Software Guard Extensions (Intel® SGX)
Discussion board focused on hardware-based isolation and memory encryption to provide extended code protection in solutions.
1521 Discussions

Impact on Switchless call performance with varying trusted_worker_threads

Arun_M
Beginner
597 Views

Hello all,

 

My Machine Specs:

Processor : Intel(R) Core(TM) i7-9850H CPU @ 2.60GHz
Physical Cores : 6
Logical Threads : 12 (6 core * 2 threads per core)

 

 

 

Scenario 1:

I've been experimenting with adjusting the trusted_worker_threads parameter from 1 to 15 while keeping the TCSNum fixed at 15. During my tests, I made an ECALL and observed varying execution times based on the number of trusted_worker_threads.

 

I noticed the following behaviour: 

  • When the number of trusted_worker_threads is lower than the number of physical cores, the ECALL execution time increases (e.g., from 1.3 ms to 1.6 ms and 1.9 ms)
  • When the number of trusted_worker_threads exceeds the number of physical cores, the ECALL execution time also increases.
  • When the number of trusted_worker_threads is same as the number of physical cores, execution time was optimised when compared to others.

Can someone explain why this behaviour occurs? What are the implications of setting trusted_worker_threads to values lower or higher than the number of physical cores?

 

Scenario 2:

In another test, I used switchless configurations by invoking 100 threads from Java to call an ECALL with TCSNum set to 100 and trusted_worker_threads set to 6. The execution time observed was 8 ms. However, when I ran the same scenario without switchless configurations (with 100 Java threads calling the same ECALL), the result was very similar, at 7.8 ms.

Questions:

  1. Why does the ECALL execution time vary with changes in the number of trusted_worker_threads, especially in relation to the number of physical cores?
  2. Why is the time difference between switchless and non-switchless configurations so minimal in the second scenario, despite the high number of threads? What factors could be influencing these results, and under what conditions might switchless configurations provide more significant benefits?
Labels (1)
0 Kudos
0 Replies
Reply