Dear All,
I am trying to write an script to calculate geometric centre of selected residues of a protein structure. Say I have a PDB file (a text containing the x, y, and z coordinates of atoms of a protein). I want to extract the X coordinates of the atoms belonging to the interested residues... (2 Replies)
hello all how can i get the type of variable in perl like
typeof(var); in javascript for instance ? to know if the variable is int or string ? (2 Replies)
Hello experts,
How we can find out,that what is type of a scalar variable? i.e a scalar var contain a number or a string.
Thanks in advance. (8 Replies)
So, I'm making a little awk script that generates a range-based histogram of a set of numbers. I've stumbled onto a strange thing. Toward the end of the process, I have this test:
if ( bindex < s )
"bindex" is the "index" of my "bin" (the array element that gets incremented whenever a... (2 Replies)
I have a question about the type of this variable
checkU= sudo cat /etc/passwd: grep $uname: wc -l
I write a script to check the existent of username that get from the keyboard. If there is no username,it will create the username else it show the 'Duplicate name" message.
The problem is it... (4 Replies)
Hi,
I want to start MY_PROGRAM in a bash script with additional parameters given in the CONFIGURATION_ARRAY.
IFS="'"
CONFIGURATION_ARRAY=( '-N 0 -m 0' '-N 0 -m 1' )
for configuration in ${CONFIGURATION_ARRAY}
do
//DEBUG
N=${configuration%-*} //-N 0
M=-${configuration##*-} //-m 0... (5 Replies)
Trying to find out whether there is a limit for the number of records that can be stored in a variable I set up this small script:
#!/usr/bin/ksh
for ((i = 1; i < 21; i++))
do
n=$(($i*100))
echo "Trying $n records:"
recs=$(head -$n error.log)
echo "$recs" | wc
done ... (9 Replies)
I'm converting a binary file to ASCII using c code.
The folllowing block of code prints correct double value 00000.000000000 on HPUNIX platform.
longi double;
/* C79 - Price Per Minute */
memcpy(&longi,&rbuff,8);
fprintf(wfp,"%015.9f ",longi);
prints : 00000.000000000
... (6 Replies)
Hello,
I am trying to concatenate a string in a bash script like this:
runCmd="docker run -e \"IMAGE_NAME=$IMAGE_NAME\" "
env | grep "$ENV_SUFFIX" | while read line; do
envCmd="-e \"${line}\" "
runCmd=$runCmd$envCmd
echo $runCmd # here concatenation works fine
done
echo... (3 Replies)
Discussion started by: czabak
3 Replies
LEARN ABOUT CENTOS
cpuid
CPUID(4) Linux Programmer's Manual CPUID(4)NAME
cpuid - x86 CPUID access device
DESCRIPTION
CPUID provides an interface for querying information about the x86 CPU.
This device is accessed by lseek(2) or pread(2) to the appropriate CPUID level and reading in chunks of 16 bytes. A larger read size means
multiple reads of consecutive levels.
The lower 32 bits of the file position is used as the incoming %eax, and the upper 32 bits of the file position as the incoming %ecx, the
latter intended for "counting" eax levels like eax=4.
This driver uses /dev/cpu/CPUNUM/cpuid, where CPUNUM is the minor number, and on an SMP box will direct the access to CPU CPUNUM as listed
in /proc/cpuinfo.
This file is protected so that it can be read only by the user root, or members of the group root.
NOTES
The CPUID instruction can be directly executed by a program using inline assembler. However this device allows convenient access to all
CPUs without changing process affinity.
Most of the information in cpuid is reported by the kernel in cooked form either in /proc/cpuinfo or through subdirectories in
/sys/devices/system/cpu. Direct CPUID access through this device should only be used in exceptional cases.
The cpuid driver is not auto-loaded. On modular kernels you might need to use the following command to load it explicitly before use:
$ modprobe cpuid
There is no support for CPUID functions that require additional input registers.
Very old x86 CPUs don't support CPUID.
SEE ALSO
Intel Corporation, Intel 64 and IA-32 Architectures Software Developer's Manual Volume 2A: Instruction Set Reference, A-M, 3-180 CPUID ref-
erence.
Intel Corporation, Intel Processor Identification and the CPUID Instruction, Application note 485.
COLOPHON
This page is part of release 3.53 of the Linux man-pages project. A description of the project, and information about reporting bugs, can
be found at http://www.kernel.org/doc/man-pages/.
Linux 2009-03-31 CPUID(4)