Server : Apache System : Linux iad1-shared-b8-43 6.6.49-grsec-jammy+ #10 SMP Thu Sep 12 23:23:08 UTC 2024 x86_64 User : dh_edsupp ( 6597262) PHP Version : 8.2.26 Disable Function : NONE Directory : /lib/python3/dist-packages/pygments/lexers/__pycache__/ |
Upload File : |
o ���a�� � @ sp d Z ddlZddlmZmZmZmZmZmZm Z ddl mZmZ ddl mZ ddlmZmZmZmZmZmZmZmZmZmZ g d�ZG dd � d e�Zd d� ZG dd � d e�ZG dd� de�ZG dd� de�ZG dd� de�Z G dd� de�Z!G dd� de�Z"G dd� de�Z#G dd� de�Z$G dd� de�Z%G dd� de�Z&G d d!� d!e�Z'G d"d#� d#e�Z(G d$d%� d%e�Z)dS )&z� pygments.lexers.asm ~~~~~~~~~~~~~~~~~~~ Lexers for assembly languages. :copyright: Copyright 2006-2021 by the Pygments team, see AUTHORS. :license: BSD, see LICENSE for details. � N)� RegexLexer�include�bygroups�using�words�DelegatingLexer�default)�CppLexer�CLexer)�DLexer) �Text�Name�Number�String�Comment�Punctuation�Other�Keyword�Operator� Whitespace)�GasLexer�ObjdumpLexer� DObjdumpLexer�CppObjdumpLexer� CObjdumpLexer� HsailLexer� LlvmLexer�LlvmMirBodyLexer�LlvmMirLexer� NasmLexer�NasmObjdumpLexer� TasmLexer� Ca65Lexer�Dasm16Lexerc @ s� e Zd ZdZdZddgZddgZdgZdZd Z d e d e d Z d Zde d Ze d�e d ejfde ejdfdejfe ejdfdefge ejfeefde ejfeejfeejfdedfdejdfdejfdejdfe d�e d�gde d eejeeeje�fde d e d eejeeejeeje�fe ejfeejfeejfd e ejfd!ejfdedfdejdfdejfdejdfe d�e d�g d"efd#efdejfd$ejfgd%efgd&�Z d'd(� Z!d)S )*r z' For Gas (AT&T) assembly code. �GAS�gas�asm�*.sz*.Sz text/x-gas� "(\\"|[^"])*"z[\w$.@-]� (?:[a-zA-Z$_]�*|\.�+)z(?:0[xX][a-fA-F0-9]+|#?-?\d+)�%�\b� whitespace�:�\.�directive-argszlock|rep(n?z)?|data\d+�instruction-args�[\r\n]+�@�#popz([;#]|//).*?\nz/[*].*?[*]/z/[*].*?\n[\w\W]*?[*]/�punctuationz([a-z0-9]+)( )(<)(z)(>)z)([-+])(�$z $'(.|\\')'�\n�\s+z/[*][\w\W]*?[*]/z[-*,.()\[\]!:]+)�rootr1 r2 r. r6 c C s, t �d| t j�r dS t �d| t j�rdS d S )Nz^\.(text|data|section)Tz^\.\w+g�������?)�re�search�M��text� r@ �5/usr/lib/python3/dist-packages/pygments/lexers/asm.py�analyse_textf s �zGasLexer.analyse_textN)"�__name__� __module__�__qualname__�__doc__�name�aliases� filenames� mimetypes�string�char� identifier�number�registerr r �Label� Attribute�Functionr �Constantr r �Integer�Variabler r �Single� Multiliner �Hexr �Char�tokensrB r@ r@ r@ rA r sz � � ���� ����<r c C sp d}ddt tjttt�fdt ttjt�fd| d t tjtttj ttjt�fd| d t tjtttj t�fd| d | | d t ttjttjtt | ��fd| d t ttjtt | ��fd| d | | d t ttjttjtt�fd| d | | d t ttjttj�fdtfd| d | d t ttjttjttjttj�fd| d t ttjttjttj�fdt fgiS )z; Common objdump lexer tokens to wrap an ASM lexer. z[0-9A-Za-z]r: z(.*?)(:)( +file format )(.*?)$z"(Disassembly of section )(.*?)(:)$�(z++)( )(<)(.*?)([-+])(0[xX][A-Za-z0-9]+)(>:)$z+)( )(<)(.*?)(>:)$z( *)(z+:)(\t)((?:z )+)( * )([a-zA-Z].*?)$z+:)( *\t)([a-zA-Z].*?)$z )+)( *)(.*?)$z )+)$z \t\.\.\.$z (\t\t\t)(z +:)( )([^\t]+)(\t)(.*?)([-+])(0xz+)$z+:)( )([^\t]+)(\t)(.*?)$z[^\n]+\n)r r rP r r r r rX r rR r �PropertyrS r )� asm_lexer�hex_rer@ r@ rA �_objdump_lexer_tokensm s` �� �� ���� ���� �� ����r_ c @ �. e Zd ZdZdZdgZdgZdgZee �Z dS )r z, For the output of ``objdump -dr``. �objdumpz *.objdumpztext/x-objdumpN)rC rD rE rF rG rH rI rJ r_ r rZ r@ r@ r@ rA r � s r c �6 e Zd ZdZdZdgZdgZdgZ� fdd�Z� Z S )r z@ For the output of ``objdump -Sr`` on compiled D files. z d-objdumpz*.d-objdumpztext/x-d-objdumpc � t � jttfi |�� d S �N)�super�__init__r r ��self�options�� __class__r@ rA rf � � zDObjdumpLexer.__init__� rC rD rE rF rG rH rI rJ rf � __classcell__r@ r@ rj rA r � � r c s: e Zd ZdZdZg d�Zg d�ZdgZ� fdd�Z� Z S )r zB For the output of ``objdump -Sr`` on compiled C++ files. �cpp-objdump)rp zc++-objdumbzcxx-objdump)z *.cpp-objdumpz *.c++-objdumpz *.cxx-objdumpztext/x-cpp-objdumpc rc rd )re rf r r rg rj r@ rA rf � rl zCppObjdumpLexer.__init__rm r@ r@ rj rA r � s r c rb )r z@ For the output of ``objdump -Sr`` on compiled C files. z c-objdumpz*.c-objdumpztext/x-c-objdumpc rc rd )re rf r r rg rj r@ rA rf � rl zCObjdumpLexer.__init__rm r@ r@ rj rA r � ro r c @ s\ e Zd ZdZdZddgZdgZdgZdZdZ d Z d e d ZdZd Z dZdZdZdZdZdZed�ed�eefde d ejfeejjfed�de ejjfde ejfeejfdejfeejfeejfdejfdefgde fgde!j"fd e!j#fgd!e e$j%fd"e$fe&d#d$d%�e$fee$fee$fd&e d' e d( e$fd)e$fd*e$fe&d+�e$fd,e$fg d-�Z'd.S )/r z= For HSAIL assembly code. .. versionadded:: 2.2 �HSAIL�hsail�hsaz*.hsailztext/x-hsail�"[^"]*?"z[a-zA-Z_][\w.]*�[0-9]+z(\$(c|s|d|q)z)\bz(align\(\d+\))z(width\((\d+|all)\))z(alloc\(agent\))z ((_ftz)?(_up|_down|_zero|_near))z�_(u8x4|s8x4|u16x2|s16x2|u8x8|s8x8|u16x4|s16x4|u32x2|s32x2|u8x16|s8x16|u16x8|s16x8|u32x4|s32x4|u64x2|s64x2|f16x2|f16x4|f16x8|f32x2|f32x4|f64x2|u8|s8|u16|s16|u32|s32|u64|s64|b128|b8|b16|b32|b64|b1|f16|f32|f64|roimg|woimg|rwimg|samp|sig32|sig64)z ((\d+\.)|(\d*\.\d+))[eE][+-]?\d+zL0[xX](([0-9a-fA-F]+\.[0-9a-fA-F]*)|([0-9a-fA-F]*\.[0-9a-fA-F]+))[pP][+-]?\d+z?0((h|H)[0-9a-fA-F]{4}|(f|F)[0-9a-fA-F]{8}|(d|D)[0-9a-fA-F]{16})r. �commentsr4 z:?�keyword�&r, �0[xX][a-fA-F0-9]+�\d+z[=<>{}\[\]()*.,:;!]|x\bz(\n|\s)+z /\*.*?\*/z//.*?\n�kernargz+\$(full|base|small|large|default|zero|near))�module� extension�pragma�prog�indirect� signature�decl�kernel�function�enablebreakexceptions�enabledetectexceptions�maxdynamicgroupsize�maxflatgridsize�maxflatworkgroupsize�requireddim�requiredgridsize�requiredworkgroupsize�requirenopartialworkgroupsr- ��suffixz_(�|�)�_kernargz(nop|imagefence)\b)��cleardetectexcept�clock�cuid� debugtrap�dim�getdetectexcept�groupbaseptr�kernargbaseptr�laneid�maxcuid� maxwaveid�packetid�setdetectexcept�waveid�workitemflatabsid�workitemflatid�nullptr�abs�bitrev�currentworkgroupsize�currentworkitemflatid�fract�ncos�neg�nexp2�nlog2�nrcp�nrsqrt�nsin�nsqrt� gridgroups�gridsize�not�sqrt�workgroupid� workgroupsize� workitemabsid� workitemid�ceil�floor�rint�trunc�add�bitmask�borrow�carry�copysign�div�rem�sub�shl�shr�and�or�xor�unpackhi�unpacklo�max�min�fma�mad� bitextract� bitselect�shuffle�cmov�bitalign� bytealign�lerp�nfma�mul�mulhi�mul24hi�mul24�mad24�mad24hi� bitinsert�combine�expand�lda�mov�pack�unpack�packcvt� unpackcvt�sad�sementp�ftos�stof�cmp�ld�st�_eq�_ne�_lt�_le�_gt�_ge�_equ�_neu�_ltu�_leu�_gtu�_geu�_num�_nan�_seq�_sne�_slt�_sle�_sgt�_sge�_snum�_snan�_sequ�_sneu�_sltu�_sleu�_sgtu�_sgeu�atomic�_ld�_st�_cas�_add�_and�_exch�_max�_min�_or�_sub�_wrapdec�_wrapinc�_xor�ret�cvt� _readonlyr� �_global�br�cbr�sbr�_scacq�_screl�_scar�_rlx�_wave�_wg�_agent�_system�ldimage�stimage�_v2�_v3�_v4�_1d�_2d�_3d�_1da�_2da�_1db�_2ddepth� _2dadepth�_width�_height�_depth�_array� _channelorder�_channeltype�querysampler�_coord�_filter�_addressing�barrier�wavebarrier�initfbar�joinfbar�waitfbar� arrivefbar� leavefbar�releasefbar�ldf�activelaneid�activelanecount�activelanemask�activelanepermute�call�scall�icall�alloca�packetcompletionsig�addqueuewriteindex�casqueuewriteindex�ldqueuereadindex�stqueuereadindex�readonly�global�private�group�spill�arg�_upi�_downi�_zeroi�_neari�_upi_sat� _downi_sat� _zeroi_sat� _neari_sat�_supi�_sdowni�_szeroi�_sneari� _supi_sat�_sdowni_sat�_szeroi_sat�_sneari_sat�_pp�_ps�_sp�_ss�_s�_p�_pp_sat�_ps_sat�_sp_sat�_ss_sat�_s_sat�_p_sat� i[1-9]\d*)r: r. rv rw N)(rC rD rE rF rG rH rI rJ rK rM �register_numberrO � alignQual� widthQual� allocQual�roundingMod�datatypeMod�float�hexfloat� ieeefloatr r r rP rU � Anonymous�Globalr rX �FloatrT r r r rW rV r �Typer rZ r@ r@ r@ rA r � sp ����� %�(� �r c @ s� e Zd ZdZdZdgZdgZdgZdZde d Z d e d Z ed�e d ej fed �de ejfde ejjfdejjfdejjfdejjfde ejfdejjfde efdefdefdefgdefdefgeddd�efed�ejfdejfgd �Zd!S )"r z! For LLVM assembly code. �LLVM�llvmz*.llztext/x-llvmrt z([-a-zA-Z$._][\w\-$.]*|r� r[ z|(\d+))r. z\s*:rw r, r4 z%\d+z@\d+z#\d+�!z!\d+zc?ry z,-?\d+(?:[.]\d+)?(?:[eE][-+]?\d+(?:[.]\d+)?)?z[=<>{}\[\]()*.,!]|x\bz (\n|\s+)+�;.*?\n(� �aarch64_sve_vector_pcs�aarch64_vector_pcs�acq_rel�acquirer� � addrspace� addrspacecast�afn�alias�aliasee�align� alignLog2� alignstackrN � allocsize�allOnes�alwaysinline�alwaysInline� amdgpu_cs� amdgpu_es� amdgpu_gfx� amdgpu_gs� amdgpu_hs� amdgpu_kernel� amdgpu_ls� amdgpu_ps� amdgpu_vsr� �any�anyregcc� appending�arcp� argmemonly�args�arm_aapcs_vfpcc�arm_aapcscc� arm_apcscc�ashrr&