Sponsored Content
Full Discussion: awk sum entire string
Top Forums Shell Programming and Scripting awk sum entire string Post 302771671 by balajesuri on Thursday 21st of February 2013 08:03:23 AM
Old 02-21-2013
Ah, yes! A silly miss.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

sort entire line based on part of the string

hey gurus, my-build1-abc my-build10-abc my-build2-abc my-build22-abc my-build3-abc basically i want to numerically sort the entire lines based on the build number. I dont zero pad the numbers because thats "how it is" ;-) sort -n won't work because it starts from the beginning. ... (10 Replies)
Discussion started by: gurpal2000
10 Replies

2. UNIX for Dummies Questions & Answers

Search for a string and copy the entire line

Hello All, I am after the script or the command which can scan the entire file for a string $PART_ID and when found to extract/copy the corresponding $PART_ID value (e.g THIRE_PTY_SOFTWARE for the 1st occurance of $PART_ID in the attached file) to a file. Appreciate your help. Thanks in... (3 Replies)
Discussion started by: forumthreads
3 Replies

3. Shell Programming and Scripting

scripting/awk help : awk sum output is not comming in regular format. Pls advise.

Hi Experts, I am adding a column of numbers with awk , however not getting correct output: # awk '{sum+=$1} END {print sum}' datafile 2.15291e+06 How can I getthe output like : 2152910 Thank you.. # awk '{sum+=$1} END {print sum}' datafile 2.15079e+06 (3 Replies)
Discussion started by: rveri
3 Replies

4. Web Development

Replacing a string in an entire mysql Database

Hi, Can someone please tell me how I can replace every occurrence of a string with another string, in the entire mysql database? What this means is, i just dont want to operate table by table. I want to search the database and automatically replace the string /opt/cacti/scripts/ with... (1 Reply)
Discussion started by: SkySmart
1 Replies

5. Shell Programming and Scripting

Print only matched string instead of entire line

Hi, I have a file whose lines are something like Tchampionspsq^@~^@^^^A^@^@^@^A^A^Aÿð^@^@^@^@^@^@^@^@^@^@^A^@^@^@^@^?ð^@^@^@^@^@^@^@?ð^@^@^@^@^@^@pppsq^@~^@#@^@^@^@^@^@^Hw^H^@^@^@^K^@^@^@^@xp^At^@^FTtime2psq^@ ~^@^^^A^@^@^@^B^A I need to extract all words matching T*psq from the file. Thing is... (4 Replies)
Discussion started by: shekhar2010us
4 Replies

6. Shell Programming and Scripting

Print entire line only if certain fixed character matches the string

Hi All, I have a file testarun.txt contains the below lines and i want to print the lines if the character positions 7-8 matches 01. 201401011111 201401022222 201402013333 201402024444 201403015555 201403026666 201404017777 201404028888 201405019999 201405020000 I am trying the... (4 Replies)
Discussion started by: Arunprasad
4 Replies

7. Shell Programming and Scripting

Regular Expression - Switch Entire String

I would like to be able to use a regular expression to find and replace entire strings, but not replace if the string is a substring in a larger string. Example: $string = "ABC ABCDEF ABC ABCDEF ABC"; Something like - $string =~ s/ABC/XYZ/g; ->Desired: $string = "XYZ ABCDEF XYZ ABCDEF... (3 Replies)
Discussion started by: rjulich
3 Replies

8. Shell Programming and Scripting

Avoid printing entire line if string not found

so im searching the process table with: ps -ef | awk -F"./rello.java" '{ print substr($0, index($0,$2)) }' I only want it to print everything that's infront of the "./rello.java". That's because im basically getting the arguments that was passed to the rello.java script. this works. ... (2 Replies)
Discussion started by: SkySmart
2 Replies

9. UNIX for Beginners Questions & Answers

Search a string and display its location on the entire string and make a text file

I want to search a small string in a large string and find the locations of the string. For this I used grep "string" -ob <file name where the large string is stored>. Now this gives me the locations of that string. Now how do I store these locations in a text file. Please use CODE tags as... (7 Replies)
Discussion started by: ANKIT ROY
7 Replies

10. UNIX for Beginners Questions & Answers

Awk: count unique elements in a field and sum their occurence across the entire file

Hi, Sure it's an easy one, but it drives me insane. input ("|" separated): 1|A,B,C,A 2|A,D,D 3|A,B,B I would like to count the occurence of each capital letters in $2 across the entire file, knowing that duplicates in each record count as 1. I am trying to get this output... (5 Replies)
Discussion started by: beca123456
5 Replies
PMC.XSCALE(3)						   BSD Library Functions Manual 					     PMC.XSCALE(3)

NAME
pmc.xscale -- measurement events for Intel XScale family CPUs LIBRARY
Performance Counters Library (libpmc, -lpmc) SYNOPSIS
#include <pmc.h> DESCRIPTION
Intel XScale CPUs are ARM CPUs based on the ARMv5e core. Second generation cores have 2 counters, while third generation cores have 4 counters. Third generation cores also have an increased number of PMC events. Intel XScale PMCs are documented in 3rd Generation Intel XScale Microarchitecture Developer's Manual, May 2007. Event Specifiers (Programmable PMCs) Intel XScale programmable PMCs support the following events: IC_FETCH External memory fetch due to L1 instruction cache miss. IC_MISS Instruction cache or TLB miss. DATA_DEPENDENCY_STALLED A data dependency stalled ITLB_MISS Instruction TLB miss. DTLB_MISS Data TLB miss. BRANCH_RETIRED Branch instruction retired (executed). BRANCH_MISPRED Branch mispredicted. INSTR_RETIRED Instructions retired (executed). DC_FULL_CYCLE L1 data cache buffer full stall. Event occurs on every cycle the condition is present. DC_FULL_CONTIG L1 data cache buffer full stall. Event occurs once for each contiguous sequence of this type of stall. DC_ACCESS L1 data cache access, not including cache operations. DC_MISS L1 data cache miss, not including cache operations. DC_WRITEBACK L1 data cache write-back. Occurs for each cache line that's written back from the cache. PC_CHANGE Software changed the program counter. BRANCH_RETIRED_ALL Branch instruction retired (executed). This event counts all branch instructions, indirect or direct. INSTR_CYCLE Count the number of microarchitecture cycles each instruction requires to issue. CP_STALL Coprocessor stalled the instruction pipeline. PC_CHANGE_ALL Software changed the program counter (includes exceptions). PIPELINE_FLUSH Pipeline flushes due to mispredictions or exceptions. BACKEND_STALL Backend stalled the instruction pipeline. MULTIPLIER_USE Multiplier used. MULTIPLIER_STALLED Multiplier stalled the instruction pipeline. DATA_CACHE_STALLED Data cache stalled the instruction pipeline. L2_CACHE_REQ L2 cache request, not including cache operations. L2_CACHE_MISS L2 cache miss, not including cache operations. ADDRESS_BUS_TRANS Address bus transaction. SELF_ADDRESS_BUS_TRANS Self initiated address bus transaction. DATA_BUS_TRANS Data bus transaction. Event Name Aliases The following table shows the mapping between the PMC-independent aliases supported by Performance Counters Library (libpmc, -lpmc) and the underlying hardware events used. Alias Event branches BRANCH_RETIRED branch-mispredicts BRANCH_MISPRED dc-misses DC_MISS ic-misses IC_MISS instructions INSTR_RETIRED SEE ALSO
pmc(3), pmc.soft(3), pmc_cpuinfo(3), pmclog(3), hwpmc(4) HISTORY
The pmc library first appeared in FreeBSD 6.0. Intel XScale support first appeared in FreeBSD 9.0. AUTHORS
The Performance Counters Library (libpmc, -lpmc) library was written by Joseph Koshy <jkoshy@FreeBSD.org>. Intel XScale support was added by Rui Paulo <rpaulo@FreeBSD.org>. CAVEATS
The Intel XScale code does not yet support sampling. BSD
December 23, 2009 BSD
All times are GMT -4. The time now is 03:30 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy