data_type
large_stringclasses
3 values
source
large_stringclasses
29 values
code
large_stringlengths
98
49.4M
filepath
large_stringlengths
5
161
message
large_stringclasses
234 values
commit
large_stringclasses
234 values
subject
large_stringclasses
418 values
critique
large_stringlengths
101
1.26M
metadata
dict
source
edk2
/** @file Bit field functions of BaseLib. Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Worker function that returns a bit field from Operand. Returns the bitfield specified by the StartBit and the...
MdePkg/Library/BaseLib/BitField.c
null
null
null
null
null
source
edk2
/** @file Utility functions to generate checksum based on 2's complement algorithm. Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.<BR> Copyright (c) 2022, Pedro Falcato. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Return...
MdePkg/Library/BaseLib/CheckSum.c
null
null
null
null
null
source
edk2
/** @file Convert 128 bit unique identifier between GUID and UUID format. Copyright (c) 2024, Arm Limited. All rights reserved.<BR> Copyright (c) Microsoft Corporation. SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /************************************************************...
MdePkg/Library/BaseLib/ConvertGuidUuid.c
null
null
null
null
null
source
edk2
/** @file Base Library CPU Functions for all architectures. Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Disables CPU interrupts and returns the interrupt state prior to the disable operation. @...
MdePkg/Library/BaseLib/Cpu.c
null
null
null
null
null
source
edk2
/** @file Base Library CPU Functions for all architectures. Copyright (c) 2006 - 2024, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include <Base.h> #include <Library/BaseLib.h> static volatile UINTN mDeadLoopComparator = 0; /** Executes an infinite loop. ...
MdePkg/Library/BaseLib/CpuDeadLoop.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Divides a 64-bit signed integer by a 64-bit signed integer and generates a 64-bit signed result and a optional 64-bit s...
MdePkg/Library/BaseLib/DivS64x64Remainder.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Divides a 64-bit unsigned integer by a 32-bit unsigned integer and generates a 64-bit unsigned result. This function...
MdePkg/Library/BaseLib/DivU64x32.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Divides a 64-bit unsigned integer by a 32-bit unsigned integer and generates a 64-bit unsigned result and an optional 3...
MdePkg/Library/BaseLib/DivU64x32Remainder.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Divides a 64-bit unsigned integer by a 64-bit unsigned integer and generates a 64-bit unsigned result and an optional 6...
MdePkg/Library/BaseLib/DivU64x64Remainder.c
null
null
null
null
null
source
edk2
/** @file Defines file-path manipulation functions. Copyright (c) 2011 - 2017, Intel Corporation. All rights reserved.<BR> Copyright (c) 2018, Dell Technologies. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include <Library/BaseMemoryLib.h> #include <Library/BaseLib.h> /** Re...
MdePkg/Library/BaseLib/FilePaths.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Returns the value of the highest bit set in a 32-bit value. Equivalent to 1 << log2(x). This function computes the v...
MdePkg/Library/BaseLib/GetPowerOfTwo32.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Returns the value of the highest bit set in a 64-bit value. Equivalent to 1 << log2(x). This function computes the v...
MdePkg/Library/BaseLib/GetPowerOfTwo64.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Returns the bit position of the highest bit set in a 32-bit value. Equivalent to log2(x). This function computes the...
MdePkg/Library/BaseLib/HighBitSet32.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Returns the bit position of the highest bit set in a 64-bit value. Equivalent to log2(x). This function computes the...
MdePkg/Library/BaseLib/HighBitSet64.c
null
null
null
null
null
source
edk2
/** @file Null stub of TdxLib Copyright (c) 2021, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include <Library/BaseLib.h> #include <Uefi/UefiBaseType.h> /** The TDCALL instruction causes a VM exit to the Intel TDX module. It is used to call guest-side In...
MdePkg/Library/BaseLib/IntelTdxNull.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Rotates a 32-bit integer left between 0 and 31 bits, filling the low bits with the high bits that were rotated. This...
MdePkg/Library/BaseLib/LRotU32.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Rotates a 64-bit integer left between 0 and 63 bits, filling the low bits with the high bits that were rotated. This...
MdePkg/Library/BaseLib/LRotU64.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Shifts a 64-bit integer left between 0 and 63 bits. The low bits are filled with zeros. The shifted value is returned. ...
MdePkg/Library/BaseLib/LShiftU64.c
null
null
null
null
null
source
edk2
/** @file Linked List Library Functions. Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** If PcdVerifyNodeInList is TRUE, ASSERTs when SecondEntry is or is not part of the same doubly-linked list as Fi...
MdePkg/Library/BaseLib/LinkedList.c
null
null
null
null
null
source
edk2
/** @file Long Jump functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Restores the CPU context that was saved with SetJump(). Restores the CPU context from the buffer specified by JumpBuffer...
MdePkg/Library/BaseLib/LongJump.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Returns the bit position of the lowest bit set in a 32-bit value. This function computes the bit position of the lowes...
MdePkg/Library/BaseLib/LowBitSet32.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Returns the bit position of the lowest bit set in a 64-bit value. This function computes the bit position of the lowes...
MdePkg/Library/BaseLib/LowBitSet64.c
null
null
null
null
null
source
edk2
/** @file Leaf math worker functions that require 64-bit arithmetic support from the compiler. Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Shifts a 64-bit integer left between 0 and 63 bits. The l...
MdePkg/Library/BaseLib/Math64.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Divides a 64-bit unsigned integer by a 32-bit unsigned integer and generates a 32-bit unsigned remainder. This funct...
MdePkg/Library/BaseLib/ModU64x32.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Multiplies a 64-bit signed integer by a 64-bit signed integer and generates a 64-bit signed result. This function mu...
MdePkg/Library/BaseLib/MultS64x64.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Multiplies a 64-bit unsigned integer by a 32-bit unsigned integer and generates a 64-bit unsigned result. This funct...
MdePkg/Library/BaseLib/MultU64x32.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Multiplies a 64-bit unsigned integer by a 64-bit unsigned integer and generates a 64-bit unsigned result. This funct...
MdePkg/Library/BaseLib/MultU64x64.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2021, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** This function is identical to perform QuickSort, except that is uses the pre-allocated buffer so the in place sorting does not...
MdePkg/Library/BaseLib/QuickSort.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Rotates a 32-bit integer right between 0 and 31 bits, filling the high bits with the low bits that were rotated. Thi...
MdePkg/Library/BaseLib/RRotU32.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Rotates a 64-bit integer right between 0 and 63 bits, filling the high bits with the high low bits that were rotated. ...
MdePkg/Library/BaseLib/RRotU64.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Shifts a 64-bit integer right between 0 and 63 bits. This high bits are filled with zeros. The shifted value is returne...
MdePkg/Library/BaseLib/RShiftU64.c
null
null
null
null
null
source
edk2
/** @file Safe String functions. Copyright (c) 2014 - 2019, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" #define RSIZE_MAX (PcdGet32 (PcdMaximumUnicodeStringLength)) #define ASCII_RSIZE_MAX (PcdGet32 (PcdMaximumAsciiStringLength)...
MdePkg/Library/BaseLib/SafeString.c
null
null
null
null
null
source
edk2
/** @file Internal ASSERT () functions for SetJump. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Worker function that checks ASSERT condition for JumpBuffer Checks ASSERT condition for JumpBuffer....
MdePkg/Library/BaseLib/SetJump.c
null
null
null
null
null
source
edk2
/** @file Unicode and ASCII string primitives. Copyright (c) 2006 - 2019, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Returns the length of a Null-terminated Unicode string. This function returns the number of Unicode char...
MdePkg/Library/BaseLib/String.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Switches the endianess of a 16-bit integer. This function swaps the bytes in a 16-bit unsigned value to switch the val...
MdePkg/Library/BaseLib/SwapBytes16.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Switches the endianess of a 32-bit integer. This function swaps the bytes in a 32-bit unsigned value to switch the val...
MdePkg/Library/BaseLib/SwapBytes32.c
null
null
null
null
null
source
edk2
/** @file Math worker functions. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Switches the endianess of a 64-bit integer. This function swaps the bytes in a 64-bit unsigned value to switch the val...
MdePkg/Library/BaseLib/SwapBytes64.c
null
null
null
null
null
source
edk2
/** @file Switch Stack functions. Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Transfers control to a function starting with a new stack. Transfers control to the function specified by EntryPoint ...
MdePkg/Library/BaseLib/SwitchStack.c
null
null
null
null
null
source
edk2
/** @file Unaligned access functions of BaseLib. Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" #pragma pack(1) typedef union { UINT16 Val16; UINT32 Val32; UINT64 Val64; } MISALIGNED; #pragma ...
MdePkg/Library/BaseLib/Unaligned.c
null
null
null
null
null
source
edk2
/** @file Common Unit Test Host functions. Copyright (c) 2020, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "UnitTestHost.h" /// /// Module global variable for simple system emulation of interrupt state /// STATIC BOOLEAN mUnitTestHostBaseLibInterruptS...
MdePkg/Library/BaseLib/UnitTestHost.c
null
null
null
null
null
source
edk2
/** @file Unit Test Host functions. Copyright (c) 2020, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #pragma once #include "BaseLibInternals.h" #include <Library/UnitTestHostBaseLib.h> /** Enables CPU interrupts. **/ VOID EFIAPI UnitTestHostBaseLibEnableInte...
MdePkg/Library/BaseLib/UnitTestHost.h
null
null
null
null
null
source
edk2
/** @file IA-32/x64 AsmDisablePaging32() Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Disables the 32-bit paging mode on the CPU. Disables the 32-bit paging mode on the CPU and returns to 32-bit p...
MdePkg/Library/BaseLib/X86DisablePaging32.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 AsmDisablePaging64() Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Disables the 64-bit paging mode on the CPU. Disables the 64-bit paging mode on the CPU and returns to 32-bit p...
MdePkg/Library/BaseLib/X86DisablePaging64.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 AsmEnablePaging32() Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Enables the 32-bit paging mode on the CPU. Enables the 32-bit paging mode on the CPU. CR0, CR3, CR4, and the pa...
MdePkg/Library/BaseLib/X86EnablePaging32.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 AsmEnablePaging64() Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Enables the 64-bit paging mode on the CPU. Enables the 64-bit paging mode on the CPU. CR0, CR3, CR4, and the pa...
MdePkg/Library/BaseLib/X86EnablePaging64.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 AsmFxRestore() Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Restores the current floating point/SSE/SSE2 context from a buffer. Restores the current floating point/SSE/SSE2 sta...
MdePkg/Library/BaseLib/X86FxRestore.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 AsmFxSave() Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Save the current floating point/SSE/SSE2 context to a buffer. Saves the current floating point/SSE/SSE2 state to the bu...
MdePkg/Library/BaseLib/X86FxSave.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 GetInterruptState() Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Retrieves the current CPU interrupt state. Returns TRUE is interrupts are currently enabled. Otherwise return...
MdePkg/Library/BaseLib/X86GetInterruptState.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 MemoryFence(). Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Used to serialize load and store operations. All loads and stores that proceed calls to this function are guaranteed to be globally visible when ...
MdePkg/Library/BaseLib/X86MemoryFence.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 MSR functions. Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Returns the lower 32-bits of a Machine Specific Register(MSR). Reads and returns the lower 32-bits of the MSR specif...
MdePkg/Library/BaseLib/X86Msr.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 PatchInstructionX86() Copyright (C) 2018, Intel Corporation. All rights reserved.<BR> Copyright (C) 2018, Red Hat, Inc. SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Patch the immediate operand of an IA32 or X64 instruction such that the byte, wor...
MdePkg/Library/BaseLib/X86PatchInstruction.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 AsmRdRandxx() Generates random number through CPU RdRand instruction. Copyright (c) 2016, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Generates a 16-bit random number through RDRAND instruction. if Ra...
MdePkg/Library/BaseLib/X86RdRand.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 AsmReadGdtr() Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Reads the current Global Descriptor Table Register(GDTR) descriptor. Reads and returns the current GDTR descriptor an...
MdePkg/Library/BaseLib/X86ReadGdtr.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 AsmReadIdtr() Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Reads the current Interrupt Descriptor Table Register(IDTR) descriptor. Reads and returns the current IDTR descriptor...
MdePkg/Library/BaseLib/X86ReadIdtr.c
null
null
null
null
null
source
edk2
/** @file SpeculationBarrier() function for IA32 and x64. Copyright (C) 2018 - 2019, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include <Library/BaseLib.h> /** Uses as a barrier to stop speculative execution. Ensures that no later instruction will execu...
MdePkg/Library/BaseLib/X86SpeculationBarrier.c
null
null
null
null
null
source
edk2
/** @file Real Mode Thunk Functions for IA32 and x64. Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" extern CONST UINT8 m16Start; extern CONST UINT16 m16Size; extern CONST UINT16 mThunk16Attr; extern CON...
MdePkg/Library/BaseLib/X86Thunk.c
null
null
null
null
null
source
edk2
/** @file IA32/X64 specific Unit Test Host functions. Copyright (c) 2020, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "UnitTestHost.h" /// /// Defines for mUnitTestHostBaseLibSegment indexes /// #define UNIT_TEST_HOST_BASE_LIB_SEGMENT_CS 0 #define U...
MdePkg/Library/BaseLib/X86UnitTestHost.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 AsmWriteGdtr() Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Writes the current Global Descriptor Table Register (GDTR) descriptor. Writes and the current GDTR descriptor specif...
MdePkg/Library/BaseLib/X86WriteGdtr.c
null
null
null
null
null
source
edk2
/** @file IA-32/x64 AsmWriteIdtr() Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Writes the current Interrupt Descriptor Table Register(IDTR) descriptor. Writes the current IDTR descriptor and retu...
MdePkg/Library/BaseLib/X86WriteIdtr.c
null
null
null
null
null
source
edk2
#------------------------------------------------------------------------------ # # ArmReadCntPctReg() for AArch64 # # Copyright (c) 2023 - 2024, Arm Limited. All rights reserved.<BR> # # SPDX-License-Identifier: BSD-2-Clause-Patent # #------------------------------------------------------------------------------ .tex...
MdePkg/Library/BaseLib/AArch64/ArmReadCntPctReg.S
null
null
null
null
null
source
edk2
;------------------------------------------------------------------------------ ; ; ArmReadCntPctReg() for AArch64 ; ; Copyright (c) 2023 - 2024, Arm Limited. All rights reserved.<BR> ; ; SPDX-License-Identifier: BSD-2-Clause-Patent ; ;------------------------------------------------------------------------------ EX...
MdePkg/Library/BaseLib/AArch64/ArmReadCntPctReg.asm
null
null
null
null
null
source
edk2
#------------------------------------------------------------------------------ # # ArmReadIdAA64Isar0Reg() for AArch64 # # Copyright (c) 2021, NUVIA Inc. All rights reserved.<BR> # # SPDX-License-Identifier: BSD-2-Clause-Patent # #------------------------------------------------------------------------------ .text .p...
MdePkg/Library/BaseLib/AArch64/ArmReadIdAA64Isar0Reg.S
null
null
null
null
null
source
edk2
;------------------------------------------------------------------------------ ; ; ArmReadIdAA64Isar0Reg() for AArch64 ; ; Copyright (c) 2021, NUVIA Inc. All rights reserved.<BR> ; ; SPDX-License-Identifier: BSD-2-Clause-Patent ; ;------------------------------------------------------------------------------ EXPORT...
MdePkg/Library/BaseLib/AArch64/ArmReadIdAA64Isar0Reg.asm
null
null
null
null
null
source
edk2
#------------------------------------------------------------------------------ # # CpuBreakpoint() for AArch64 # # Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR> # Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR> # Portions copyright (c) 2011 - 2013, ARM Ltd. All rights r...
MdePkg/Library/BaseLib/AArch64/CpuBreakpoint.S
null
null
null
null
null
source
edk2
;------------------------------------------------------------------------------ ; ; CpuBreakpoint() for AArch64 ; ; Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR> ; Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR> ; Portions copyright (c) 2011 - 2013, ARM Ltd. All rights r...
MdePkg/Library/BaseLib/AArch64/CpuBreakpoint.asm
null
null
null
null
null
source
edk2
#------------------------------------------------------------------------------ # # DisableInterrupts() for AArch64 # # Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR> # Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR> # Portions copyright (c) 2011 - 2013, ARM Ltd. All righ...
MdePkg/Library/BaseLib/AArch64/DisableInterrupts.S
null
null
null
null
null
source
edk2
;------------------------------------------------------------------------------ ; ; DisableInterrupts() for AArch64 ; ; Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR> ; Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR> ; Portions copyright (c) 2011 - 2013, ARM Ltd. All righ...
MdePkg/Library/BaseLib/AArch64/DisableInterrupts.asm
null
null
null
null
null
source
edk2
#------------------------------------------------------------------------------ # # EnableInterrupts() for AArch64 # # Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR> # Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR> # Portions copyright (c) 2011 - 2013, ARM Ltd. All right...
MdePkg/Library/BaseLib/AArch64/EnableInterrupts.S
null
null
null
null
null
source
edk2
;------------------------------------------------------------------------------ ; ; EnableInterrupts() for AArch64 ; ; Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR> ; Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR> ; Portions copyright (c) 2011 - 2013, ARM Ltd. All right...
MdePkg/Library/BaseLib/AArch64/EnableInterrupts.asm
null
null
null
null
null
source
edk2
#------------------------------------------------------------------------------ # # GetInterruptState() function for AArch64 # # Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR> # Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR> # Portions copyright (c) 2011 - 2013, ARM Ltd....
MdePkg/Library/BaseLib/AArch64/GetInterruptsState.S
null
null
null
null
null
source
edk2
;------------------------------------------------------------------------------ ; ; GetInterruptState() function for AArch64 ; ; Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR> ; Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR> ; Portions copyright (c) 2011 - 2013, ARM Ltd....
MdePkg/Library/BaseLib/AArch64/GetInterruptsState.asm
null
null
null
null
null
source
edk2
/** @file SwitchStack() function for ARM. Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR> Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Transfers control to a function starti...
MdePkg/Library/BaseLib/AArch64/InternalSwitchStack.c
null
null
null
null
null
source
edk2
##------------------------------------------------------------------------------ # # MemoryFence() for AArch64 # # Copyright (c) 2013, ARM Ltd. All rights reserved. # # SPDX-License-Identifier: BSD-2-Clause-Patent # ##------------------------------------------------------------------------------ .text .p2align 2 GCC_...
MdePkg/Library/BaseLib/AArch64/MemoryFence.S
null
null
null
null
null
source
edk2
;------------------------------------------------------------------------------ ; ; MemoryFence() for AArch64 ; ; Copyright (c) 2013, ARM Ltd. All rights reserved. ; ; SPDX-License-Identifier: BSD-2-Clause-Patent ; ;------------------------------------------------------------------------------ EXPORT MemoryFence A...
MdePkg/Library/BaseLib/AArch64/MemoryFence.asm
null
null
null
null
null
source
edk2
#------------------------------------------------------------------------------ # # Copyright (c) 2009-2013, ARM Ltd. All rights reserved. # SPDX-License-Identifier: BSD-2-Clause-Patent # #------------------------------------------------------------------------------ .text .p2align 3 GCC_ASM_EXPORT(SetJump) GCC_ASM_E...
MdePkg/Library/BaseLib/AArch64/SetJumpLongJump.S
null
null
null
null
null
source
edk2
;------------------------------------------------------------------------------ ; ; Copyright (c) 2009-2013, ARM Ltd. All rights reserved. ; SPDX-License-Identifier: BSD-2-Clause-Patent ; ;------------------------------------------------------------------------------ EXPORT SetJump EXPORT InternalLongJump EXTER...
MdePkg/Library/BaseLib/AArch64/SetJumpLongJump.asm
null
null
null
null
null
source
edk2
##------------------------------------------------------------------------------ # # SpeculationBarrier() for AArch64 # # Copyright (c) 2019, Linaro Ltd. All rights reserved. # # SPDX-License-Identifier: BSD-2-Clause-Patent # ##------------------------------------------------------------------------------ .text .p2ali...
MdePkg/Library/BaseLib/AArch64/SpeculationBarrier.S
null
null
null
null
null
source
edk2
;------------------------------------------------------------------------------ ; ; SpeculationBarrier() for AArch64 ; ; Copyright (c) 2019, Linaro Ltd. All rights reserved. ; ; SPDX-License-Identifier: BSD-2-Clause-Patent ; ;------------------------------------------------------------------------------ EXPORT Specu...
MdePkg/Library/BaseLib/AArch64/SpeculationBarrier.asm
null
null
null
null
null
source
edk2
#------------------------------------------------------------------------------ # # Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR> # Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR> # Portions copyright (c) 2011 - 2013, ARM Limited. All rights reserved.<BR> # SPDX-License-...
MdePkg/Library/BaseLib/AArch64/SwitchStack.S
null
null
null
null
null
source
edk2
;------------------------------------------------------------------------------ ; ; Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR> ; Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR> ; Portions copyright (c) 2011 - 2013, ARM Limited. All rights reserved.<BR> ; SPDX-License-...
MdePkg/Library/BaseLib/AArch64/SwitchStack.asm
null
null
null
null
null
source
edk2
/** @file Base Library CPU Functions for EBC Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" extern UINT64 _break ( CHAR8 BreakCode ); /** Generates a breakpoint on the CPU. Generates a breakpoint ...
MdePkg/Library/BaseLib/Ebc/CpuBreakpoint.c
null
null
null
null
null
source
edk2
/** @file Implementation of SetJump() and LongJump() on EBC. SetJump() and LongJump() are not currently supported for the EBC processor type. Implementation for EBC just returns 0 for SetJump(), and ASSERT() for LongJump(). Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-...
MdePkg/Library/BaseLib/Ebc/SetJumpLongJump.c
null
null
null
null
null
source
edk2
/** @file SpeculationBarrier() function for EBC. Copyright (C) 2018, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Uses as a barrier to stop speculative execution. Ensures that no later instruction will execute speculatively, until all prior instructio...
MdePkg/Library/BaseLib/Ebc/SpeculationBarrier.c
null
null
null
null
null
source
edk2
/** @file Switch Stack functions. Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Transfers control to a function starting with a new stack. Transfers control to the function specified by EntryPoint ...
MdePkg/Library/BaseLib/Ebc/SwitchStack.c
null
null
null
null
null
source
edk2
/** @file 64-bit arithmetic right shift function for IA-32. Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Shifts a 64-bit integer right between 0 and 63 bits. The high bits are filled with original integer's bit 63. The shifted v...
MdePkg/Library/BaseLib/Ia32/ARShiftU64.c
null
null
null
null
null
source
edk2
/** @file CpuBreakpoint function. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Microsoft Visual Studio 7.1 Function Prototypes for I/O Intrinsics. **/ void __debugbreak ( VOID ); #pragma intrinsic(__debugbreak) /** Genera...
MdePkg/Library/BaseLib/Ia32/CpuBreakpoint.c
null
null
null
null
null
source
edk2
/** @file AsmCpuid function. Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Retrieves CPUID information. Executes the CPUID instruction with EAX set to the value specified by Index. This function always returns Index. If Eax ...
MdePkg/Library/BaseLib/Ia32/CpuId.c
null
null
null
null
null
source
edk2
/** @file AsmCpuidEx function. Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Retrieves CPUID information using an extended leaf identifier. Executes the CPUID instruction with EAX set to the value specified by Index and ECX se...
MdePkg/Library/BaseLib/Ia32/CpuIdEx.c
null
null
null
null
null
source
edk2
/** @file CpuPause function. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Requests CPU to pause for a short period of time. Requests CPU to pause for a short period of time. Typically used in MP systems to prevent memory star...
MdePkg/Library/BaseLib/Ia32/CpuPause.c
null
null
null
null
null
source
edk2
/** @file AsmDisableCache function Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Set CD bit and clear NW bit of CR0 followed by a WBINVD. Disables the caches by setting the CD bit of CR0 to 1, clearing the NW bit of CR0 to 0, ...
MdePkg/Library/BaseLib/Ia32/DisableCache.c
null
null
null
null
null
source
edk2
/** @file DisableInterrupts function. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Disables CPU interrupts. **/ VOID EFIAPI DisableInterrupts ( VOID ) { _asm { cli } }
MdePkg/Library/BaseLib/Ia32/DisableInterrupts.c
null
null
null
null
null
source
edk2
/** @file AsmDisablePaging32 function. Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Disables the 32-bit paging mode on the CPU. Disables the 32-bit paging mode on the CPU and returns to 32-bit pro...
MdePkg/Library/BaseLib/Ia32/DisablePaging32.c
null
null
null
null
null
source
edk2
/** @file Integer division worker functions for Ia32. Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Worker function that Divides a 64-bit signed integer by a 64-bit signed integer and generates a 6...
MdePkg/Library/BaseLib/Ia32/DivS64x64Remainder.c
null
null
null
null
null
source
edk2
/** @file Calculate the quotient of a 64-bit integer by a 32-bit integer Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Divides a 64-bit unsigned integer by a 32-bit unsigned integer and generates a 64-bit unsigned result. This...
MdePkg/Library/BaseLib/Ia32/DivU64x32.c
null
null
null
null
null
source
edk2
/** @file Set error flag for all division functions Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Divides a 64-bit unsigned integer by a 32-bit unsigned integer and generates a 64-bit unsigned result and an optional 32-bit unsign...
MdePkg/Library/BaseLib/Ia32/DivU64x32Remainder.c
null
null
null
null
null
source
edk2
/** @file AsmEnableCache function Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Perform a WBINVD and clear both the CD and NW bits of CR0. Enables the caches by executing a WBINVD instruction and then clear both the CD and NW ...
MdePkg/Library/BaseLib/Ia32/EnableCache.c
null
null
null
null
null
source
edk2
/** @file EnableDisableInterrupts function Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Enables CPU interrupts for the smallest window required to capture any pending interrupts. **/ VOID EFIAPI EnableDisableInterrupts ( VOID...
MdePkg/Library/BaseLib/Ia32/EnableDisableInterrupts.c
null
null
null
null
null
source
edk2
/** @file EnableInterrupts function Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Enables CPU interrupts. **/ VOID EFIAPI EnableInterrupts ( VOID ) { _asm { sti } }
MdePkg/Library/BaseLib/Ia32/EnableInterrupts.c
null
null
null
null
null
source
edk2
/** @file AsmEnablePaging32 function Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ #include "BaseLibInternals.h" /** Enables the 32-bit paging mode on the CPU. Enables the 32-bit paging mode on the CPU. CR0, CR3, CR4, and the page ...
MdePkg/Library/BaseLib/Ia32/EnablePaging32.c
null
null
null
null
null
source
edk2
/** @file AsmFlushCacheLine function Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /** Flushes a cache line from all the instruction and data caches within the coherency domain of the CPU. Flushed the cache line specified by Linea...
MdePkg/Library/BaseLib/Ia32/FlushCacheLine.c
null
null
null
null
null