__umulh

Microsoft-spezifisch

Gibt die oberen 64 Bits des Produkts von zwei 64-Bit-Ganzzahlen ohne Vorzeichen zurück.

Syntax

unsigned __int64 __umulh(
   unsigned __int64 a,
   unsigned __int64 b
);

Parameter

a
[in] Die erste zu multiplizierende Zahl.

b
[in] Die zweite zu multiplizierende Zahl.

Rückgabewert

Die oberen 64 Bits de 128-Bit-Ergebnisses der Multiplikation.

Anforderungen

Intrinsic Aufbau
__umulh x64, ARM64

Headerdatei<intrin.h>

Hinweise

Diese Routinen sind nur als systeminterne Funktionen verfügbar.

Beispiel

// umulh.cpp
// processor: X64
#include <cstdio>
#include <intrin.h>

int main()
{
    unsigned __int64 i = 0x10;
    unsigned __int64 j = 0xFEDCBA9876543210;
    unsigned __int64 k = i * j; // k has the low 64 bits
                                // of the product.
    unsigned __int64 result;
    result = __umulh(i, j); // result has the high 64 bits
                            // of the product.
    printf_s("0x%016I64x * 0x%016I64x = 0x%016I64x_%016I64x \n", i, j, result, k);
    return 0;
}
0x0000000000000010 * 0xfedcba9876543210 = 0x000000000000000f_edcba98765432100

Ende Microsoft-spezifisch

Siehe auch

Systeminterne Compiler