From 82ba818ff456bcd6d56a06226e3f27e98fbb55c3 Mon Sep 17 00:00:00 2001 From: Craig Jennings Date: Thu, 14 Aug 2025 22:58:58 -0500 Subject: removing all downloaded devdocs files --- devdocs/gcc~13/multi-alternative.html | 8 -------- 1 file changed, 8 deletions(-) delete mode 100644 devdocs/gcc~13/multi-alternative.html (limited to 'devdocs/gcc~13/multi-alternative.html') diff --git a/devdocs/gcc~13/multi-alternative.html b/devdocs/gcc~13/multi-alternative.html deleted file mode 100644 index 77a7f39d..00000000 --- a/devdocs/gcc~13/multi-alternative.html +++ /dev/null @@ -1,8 +0,0 @@ -

6.47.3.2 Multiple Alternative Constraints

Sometimes a single instruction has multiple alternative sets of possible operands. For example, on the 68000, a logical-or instruction can combine register or an immediate value into memory, or it can combine any kind of operand into a register; but it cannot combine one memory location into another.

These constraints are represented as multiple alternatives. An alternative can be described by a series of letters for each operand. The overall constraint for an operand is made from the letters for this operand from the first alternative, a comma, the letters for this operand from the second alternative, a comma, and so on until the last alternative. All operands for a single instruction must have the same number of alternatives.

So the first alternative for the 68000’s logical-or could be written as "+m" (output) : "ir" (input). The second could be "+r" -(output): "irm" (input). However, the fact that two memory locations cannot be used in a single instruction prevents simply using "+rm" -(output) : "irm" (input). Using multi-alternatives, this might be written as "+m,r" (output) : "ir,irm" (input). This describes all the available alternatives to the compiler, allowing it to choose the most efficient one for the current conditions.

There is no way within the template to determine which alternative was chosen. However you may be able to wrap your asm statements with builtins such as __builtin_constant_p to achieve the desired results.

-

- © Free Software Foundation
Licensed under the GNU Free Documentation License, Version 1.3.
- https://gcc.gnu.org/onlinedocs/gcc-13.1.0/gcc/Multi-Alternative.html -

-
-- cgit v1.2.3