Coverage Report

Created: 2024-10-17 06:29

/src/hbfa-fl/HBFA/UefiHostTestPkg/Library/BaseLibHost/RShiftU64.c
Line
Count
Source
1
/** @file
2
  Math worker functions.
3
4
  Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
5
  SPDX-License-Identifier: BSD-2-Clause-Patent
6
7
**/
8
9
#include <Base.h>
10
#include <Library/BaseLib.h>
11
#include <Library/DebugLib.h>
12
13
UINT64
14
EFIAPI
15
InternalMathRShiftU64 (
16
  IN      UINT64                    Operand,
17
  IN      UINTN                     Count
18
  );
19
20
/**
21
  Shifts a 64-bit integer right between 0 and 63 bits. This high bits are
22
  filled with zeros. The shifted value is returned.
23
24
  This function shifts the 64-bit value Operand to the right by Count bits. The
25
  high Count bits are set to zero. The shifted value is returned.
26
27
  If Count is greater than 63, then ASSERT().
28
29
  @param  Operand The 64-bit operand to shift right.
30
  @param  Count   The number of bits to shift right.
31
32
  @return Operand >> Count.
33
34
**/
35
UINT64
36
EFIAPI
37
RShiftU64 (
38
  IN      UINT64                    Operand,
39
  IN      UINTN                     Count
40
  )
41
67
{
42
67
  ASSERT (Count < 64);
43
67
  return InternalMathRShiftU64 (Operand, Count);
44
67
}