SIMD FP32-to-BF16 Interleaving Without Cross-Lane Shuffles

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Existing down-conversion processes for floating-point values from FP32 to BF16 often require cross-lane shuffles, leading to inefficient use of processing resources, especially when BF16 is used as an intermediate representation in computations or for memory footprint reduction.

Innovation Solution

A two-source down-convert and interleave instruction is introduced, which converts float32 elements from two SIMD registers into bfloat16 values and interleaves them without cross-lane shuffles, allowing for faster down-conversion and up-conversion by storing each bfloat16 value in the same lane as its corresponding float32 value.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If existing down-conversion processes are used to convert FP32 to BF16, then conversion is achieved, but cross-lane shuffles are required leading to inefficient use of processing resources

Engineering Contradiction:
Improveconversion efficiencyVSAvoidprocessing resource requirements
Core Design Contradiction:
ProductivityVSDevice complexity

Solution Approach 1:

The patent segments the conversion process into lane-specific operations where each lane independently converts FP32 values to BF16 values without requiring data exchange between lanes. This segmentation eliminates cross-lane shuffles and allows parallel processing within each lane, improving conversion efficiency while reducing processing resource requirements.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent reorganizes the data layout and conversion approach to operate within single lanes rather than requiring cross-lane operations. By changing the operational dimension from inter-lane to intra-lane processing, the patent eliminates the need for complex shuffle operations and reduces processing complexity while maintaining conversion functionality.

Inventive Principle:
Principle #17Another dimension (Dimensionality change)

2Productivity

If cross-lane shuffles are performed during down-conversion, then conversion is completed, but processing overhead increases

Engineering Contradiction:
Improveconversion speedVSAvoidprocessing overhead time
Core Design Contradiction:
ProductivityVSLoss of time

Solution Approach 1:

The patent performs preliminary organization of FP32 values into lane-specific groups before conversion, ensuring that each lane has all the data it needs for independent conversion. This preliminary arrangement eliminates the need for subsequent cross-lane shuffles and reduces processing overhead time while maintaining conversion speed.

Inventive Principle:
Principle #10Preliminary action

3Productivity

If cross-lane shuffles are used in down-conversion, then conversion is achieved, but memory bandwidth requirements increase

Engineering Contradiction:
Improveconversion throughputVSAvoidmemory bandwidth
Core Design Contradiction:
ProductivityVSQuantity of substance

Solution Approach 1:

The patent segments memory access patterns to align with lane boundaries, allowing each lane to access memory independently without requiring data to be shuffled across lanes. This segmentation reduces memory bandwidth requirements by eliminating redundant memory accesses associated with cross-lane shuffles while maintaining conversion throughput.

Inventive Principle:
Principle #1Segmentation

Data Source

PatentEP3716048B1Apparatus and method for down-converting and interleaving multiple floating point values
Publication Date: 2023.11.22 INTEL CORP
  • EP3716048B1 patent drawingFigure 1A
  • EP3716048B1 patent drawingFigure 1B
  • EP3716048B1 patent drawingFigure 2A~2C

AI summary

An apparatus and method down-converting and interleaving data elements. For example, one embodiment of a processor comprises: a decoder to decode a first instruction to generate a decoded instruction; a first source register to store a first plurality of packed data elements; a second source register to store a second plurality of packed data elements; a destination register to store a third plurality and a fourth plurality of packed data elements, each of the third and fourth plurality of packed data elements to be encoded with fewer bits than each of the first and second plurality of packed data elements; execution circuitry to execute the decoded instruction, the execution circuitry comprising: down-conversion circuitry to down-convert each of the first plurality of packed data elements to generate one of the third plurality of packed data elements and to down-convert each of the second plurality of packed data elements to generate one of the fourth plurality of packed data elements; interleave circuitry to interleave the third plurality of packed data elements with the fourth plurality of packed data elements within the destination register.