관리-도구
편집 파일: function_cpuinfo_check.cpython-39.pyc
a ����,�g�����������������������@���s<���d�dl�Z�d�dlZddlmZ�ej���ZG�dd��dej�Z dS�)�����N����)�basec�����������������������s,���e�Zd�ZdZ��fdd�Z��fdd�Z���ZS�)� cpuinfo_checka��� Checks regexes against /proc/cpuinfo. Accepts arguments in the following form: REGEX1, STR1, REGEX2, STR2, ...[, STR_FALLBACK] If REGEX1 matches something in /proc/cpuinfo it expands to STR1, if REGEX2 matches it expands to STR2. It stops on the first match, i.e. if REGEX1 matches, no more regexes are processed. If none regex matches it expands to STR_FALLBACK. If there is no fallback, it expands to empty string. c��������������������s���t�t|���ddd��d�S�)Nr���r�������)�superr����__init__)�self�� __class__���S/usr/lib/python3.9/site-packages/tuned/profiles/functions/function_cpuinfo_check.pyr������s����zcpuinfo_check.__init__c��������������������s����t�t|���|�sd�S�|�j�d�}tdt|�d�D�]8}|d�t|�k�r0t�||�|tj �r0||d����S�q0t|�d�r~|d�S�dS�d�S�)Nz /proc/cpuinfor���r���r��������) r���r����executeZ_cmdZ read_file�range�len�re�search� MULTILINE)r����argsZcpuinfo�ir ���r���r���r������s����zcpuinfo_check.execute)�__name__� __module__�__qualname__�__doc__r���r���� __classcell__r���r���r ���r���r������s��� r���) r���Z tuned.logsZtunedr���r���Zlogs�get�logZFunctionr���r���r���r���r����<module>���s���