×

Efficient generation of SIMD code in presence of multi-threading and other false sharing conditions and in machines having memory protection support

  • US 7,730,463 B2
  • Filed: 02/21/2006
  • Issued: 06/01/2010
  • Est. Priority Date: 02/21/2006
  • Status: Active Grant
First Claim
Patent Images

1. A computer implemented method for automatically generating SIMD code, comprising:

  • analyzing, by a processing unit, data to be accessed by a targeted loop, the targeted loop comprising at least one statement, each at least one statement having at least one memory reference, to determine whether memory accesses are both memory protection system safe and false sharing safe;

    responsive to a determination that memory accesses are both memory protection system safe and false sharing safe, simdizing the targeted loop;

    responsive to a determination that memory accesses are not both memory protection system safe and false sharing safe, determining whether a scheme can be applied in which safety does not need to be guaranteed;

    responsive to a determination that a scheme in which safety does not need to be guaranteed can be applied, applying the scheme and simdizing the targeted loop according to the applied scheme;

    responsive to a determination that a scheme in which safety does not need to be guaranteed cannot be applied, determining whether padding is appropriate;

    responsive to a determination that padding is appropriate, padding the data and simdizing the targeted loop; and

    responsive to a determination that padding is not appropriate, generating non-simdized code based on the targeted loop for handling boundary conditions, simdizing the targeted loop, and combining the simdized targeted loop with the non-simdized code.

View all claims
  • 2 Assignments
Timeline View
Assignment View
    ×
    ×