rpms/stapitrace/devel itrace-bfd-config.patch, NONE, 1.1 itrace-f11-fixes_for-upstream.patch, NONE, 1.1 stapitrace-build-fixes.patch, NONE, 1.1 stapitrace-insn-update.patch, NONE, 1.1 .cvsignore, 1.3, 1.4 sources, 1.4, 1.5 stapitrace.spec, 1.25, 1.26
Maynard Johnson
maynardj at fedoraproject.org
Wed Apr 8 17:09:21 UTC 2009
- Previous message (by thread): rpms/gnome-bluetooth/devel .cvsignore, 1.11, 1.12 gnome-bluetooth.spec, 1.65, 1.66 sources, 1.12, 1.13 sendto-connect-fix.patch, 1.1, NONE
- Next message (by thread): rpms/amarok/devel amarok-2.0.2-fix_lastfm_auth.patch, NONE, 1.1 amarok.spec, 1.144, 1.145
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: maynardj
Update of /cvs/pkgs/rpms/stapitrace/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv25156
Modified Files:
.cvsignore sources stapitrace.spec
Added Files:
itrace-bfd-config.patch itrace-f11-fixes_for-upstream.patch
stapitrace-build-fixes.patch stapitrace-insn-update.patch
Log Message:
Fix ppc64 build failure and revert to older source snapshot
itrace-bfd-config.patch:
--- NEW FILE itrace-bfd-config.patch ---
diff -paur Dpiperf-orig/configure.in Dpiperf-update/configure.in
--- Dpiperf-orig/configure.in 2009-04-03 10:18:44.000000000 -0400
+++ Dpiperf-update/configure.in 2009-04-03 15:46:53.000000000 -0400
@@ -19,7 +19,16 @@ AC_PROG_RANLIB
AC_CHECK_LIB([c], [atoi], [], [AC_MSG_ERROR([[Please install libc.]])])
AC_CHECK_LIB([dl], [dlsym], [], [AC_MSG_ERROR([[Please install libdl.]])])
AC_CHECK_LIB([iberty], [cplus_demangle], [], [AC_MSG_ERROR([[Please install libiberty (binutils package).]])])
-#AC_CHECK_LIB([bfd], [bfd_get_elf_phdrs], [], [AC_MSG_ERROR([[Please install libbfd (binutils package).]])])
+AC_CHECK_LIB(bfd, bfd_openr,[LIBS="-lbfd $LIBS"; BINUTILS_LIBS="-liberty -lbfd"],
+ [AC_CHECK_LIB(z, compress,
+dnl Use a different bfd function here so as not to use cached result from above
+ [AC_CHECK_LIB(bfd, bfd_fdopenr, [LIBS="-lbfd -lz $LIBS"; BINUTILS_LIBS="-liberty -lbfd -lz"],
+ [AC_MSG_ERROR([bfd library not found])], -lz)
+ ],
+ [AC_MSG_ERROR([libz library not found; required by libbfd])])
+ ]
+)
+AC_SUBST(BINUTILS_LIBS)
# Checks for header files.
AC_CHECK_HEADERS([bfd.h], [], [AC_MSG_ERROR([[Please make sure you have bfd.h header - please install binutils-devel package]])])
diff -paur Dpiperf-orig/src/a2n/genmsi/Makefile.am Dpiperf-update/src/a2n/genmsi/Makefile.am
--- Dpiperf-orig/src/a2n/genmsi/Makefile.am 2009-04-03 10:18:44.000000000 -0400
+++ Dpiperf-update/src/a2n/genmsi/Makefile.am 2009-04-03 12:37:29.000000000 -0400
@@ -13,11 +13,11 @@ BUILT_SOURCES = bdate.h
if two_a2n
-AM_LDFLAGS = -L${prefix}/src/a2n/ -la2n2 -liberty
+AM_LDFLAGS = -L${prefix}/src/a2n/ -la2n2 $BINUTILS_LIBS
else
-AM_LDFLAGS = -L${prefix}/src/a2n/ -la2n -liberty
+AM_LDFLAGS = -L${prefix}/src/a2n/ -la2n $BINUTILS_LIBS
endif
diff -paur Dpiperf-orig/src/a2n/Makefile.am Dpiperf-update/src/a2n/Makefile.am
--- Dpiperf-orig/src/a2n/Makefile.am 2009-04-03 10:18:44.000000000 -0400
+++ Dpiperf-update/src/a2n/Makefile.am 2009-04-03 12:36:30.000000000 -0400
@@ -53,10 +53,10 @@ liba2n2_so_SOURCES = \
util.c
liba2n2_so_LDADD = \
- -liberty -ldl -lc ${bfd_dir}/${bfd_name}
+ $BINUTILS_LIBS -ldl -lc ${bfd_dir}/${bfd_name}
liba2n_so_LDADD = \
- -liberty -ldl -lc
+ $BINUTILS_LIBS -ldl -lc
liba2n2_so_CFLAGS = -I ${top_srcdir}/INCLUDE \
-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE \
@@ -100,12 +100,12 @@ liba2n_so_SOURCES = ${liba2n_SOURCES}
if static_bfd
liba2n_so_LDADD = \
- -ldl -lc ${bfd_dir}/libbfd.a -liberty
+ -ldl -lc ${bfd_dir}/libbfd.a $BINUTILS_LIBS
else
liba2n_so_LDADD = \
- -liberty -ldl -lc ${bfd_dir}/${bfd_name}
+ $BINUTILS_LIBS -ldl -lc ${bfd_dir}/${bfd_name}
endif
diff -paur Dpiperf-orig/src/post/Makefile.am Dpiperf-update/src/post/Makefile.am
--- Dpiperf-orig/src/post/Makefile.am 2009-04-03 10:18:44.000000000 -0400
+++ Dpiperf-update/src/post/Makefile.am 2009-04-03 14:36:34.000000000 -0400
@@ -24,7 +24,7 @@ if two_a2n
EXTRA_LDADD = \
${bfd_dir}/${opcodes_name} \
- -L${prefix}/src/a2n -la2n2 -liberty -ldl -lc
+ -L${prefix}/src/a2n -la2n2 ${BINUTILS_LIBS} -ldl -lc
else
@@ -41,11 +41,11 @@ EXTRA_LDADD = \
${prefix}/src/a2n/liba2n_a-linuxval.o \
${prefix}/src/a2n/liba2n_a-saveres.o \
${prefix}/src/a2n/liba2n_a-util.o \
- -liberty
+ ${BINUTILS_LIBS}
else
EXTRA_LDADD = \
${bfd_dir}/${opcodes_name} \
- -L${prefix}/src/a2n -la2n -liberty -ldl -lc
+ -L${prefix}/src/a2n -la2n ${BINUTILS_LIBS} -ldl -lc
endif
endif
itrace-f11-fixes_for-upstream.patch:
--- NEW FILE itrace-f11-fixes_for-upstream.patch ---
diff -paur Dpiperf/src/driver/pi_btrace.c Dpiperf-fixes/src/driver/pi_btrace.c
--- Dpiperf/src/driver/pi_btrace.c 2009-03-12 17:36:07.000000000 -0400
+++ Dpiperf-fixes/src/driver/pi_btrace.c 2009-03-13 19:18:08.000000000 -0400
@@ -367,6 +367,7 @@ int SoftTraceOn(void)
// PPC64 info
addr.cval = *(unsigned long *)ppc_tb_freq_location;
#ifndef STAP_ITRACE
+ addr.cval = 0ULL;
PerfTraceHookSimple2(driver_info.mte_type, SYS_INFO_MAJOR,
SFT_HOOK_SYSINFO_TIME_BASE_MINOR,
(uint32_t)addr.sval.low,
@@ -895,8 +896,11 @@ char * set_segment_name(MTE_HOOK * hook,
else
hook->NT_ts = 0;
} else {
+#endif // STAP_ITRACE
+
// Anonymous, check whether we want to trace it
if (MappedData->TraceAnonMTE) {
+#ifndef STAP_ITRACE
seg_name = name_buffer;
#if !defined(CONFIG_64BIT)
sprintf(seg_name, "anon-%s-%08lX-%08lX", tp->comm, vma->vm_start, vma->vm_end);
@@ -904,9 +908,11 @@ char * set_segment_name(MTE_HOOK * hook,
sprintf(seg_name, "anon-%s-%016lX-%016lX", tp->comm, vma->vm_start, vma->vm_end);
#endif
hook->NT_ts = 0xFFFFFFF1;
+#endif // STAP_ITRACE
} else {
seg_name = NULL;
}
+#ifndef STAP_ITRACE
}
return(seg_name);
}
diff -paur Dpiperf/src/driver/pi_inspector.c Dpiperf-fixes/src/driver/pi_inspector.c
--- Dpiperf/src/driver/pi_inspector.c 2009-01-19 11:57:20.000000000 -0500
+++ Dpiperf-fixes/src/driver/pi_inspector.c 2009-03-12 14:37:38.000000000 -0400
@@ -70,11 +70,11 @@ int pi_file_error = 0;
#ifndef STAP_ITRACE // DEFS
PIDriverInfo driver_info = {
.num_cpus = 1,
+ .mte_type = TRACE_TYPE, // Buffer type for MTE hooks
#endif // STAP_ITRACE DEFS
.mec_table = {0},
.trace_buff_size = 0,
.mte_buff_size = 0,
- .mte_type = TRACE_TYPE, // Buffer type for MTE hooks
#ifndef _ST_ITRACE_ONLY
.ptt_user_list = {0}, // PIDs who've done PttInit()
.tprof_mode = TPROF_MODE_TIME,
diff -paur Dpiperf/src/driver/pi_inspector.h Dpiperf-fixes/src/driver/pi_inspector.h
--- Dpiperf/src/driver/pi_inspector.h 2009-01-19 11:57:20.000000000 -0500
+++ Dpiperf-fixes/src/driver/pi_inspector.h 2009-03-12 14:36:56.000000000 -0400
@@ -86,11 +86,11 @@ typedef struct _PIDriver_Info
uint32_t cpu_model;
uint32_t cpu_architecture;
uint32_t num_cpus;
+ uint32_t mte_type; // Buffer type for MTE hooks
#endif // STAP_ITRACE DEFS
uint8_t mec_table[NUM_MAJORS];
uint32_t trace_buff_size;
uint32_t mte_buff_size;
- uint32_t mte_type; // Buffer type for MTE hooks
uint32_t num_perf_ctrs;
uint8_t hyper_threading_enabled;
#ifndef _ST_ITRACE_ONLY
diff -paur Dpiperf/src/driver/ppc64/pi_cpuinit.c Dpiperf-fixes/src/driver/ppc64/pi_cpuinit.c
--- Dpiperf/src/driver/ppc64/pi_cpuinit.c 2008-10-02 10:42:57.000000000 -0400
+++ Dpiperf-fixes/src/driver/ppc64/pi_cpuinit.c 2009-03-12 15:11:34.000000000 -0400
@@ -58,9 +58,9 @@ int pitrace_cpu_init(void)
unsigned long pvr;
struct device_node * cpu_node;
unsigned int * fp;
+#ifndef STAP_ITRACE // CPU_INIT
unsigned long cpu_freq = 0;
-#ifndef STAP_ITRACE // CPU_INIT
cpu_node = of_find_node_by_type(NULL, "cpu");
if ( cpu_node ) {
fp = (unsigned int *)of_get_property(cpu_node, "ibm,extended-clock-frequency", NULL);
diff -paur Dpiperf/src/driver/ppc64/pi_itrace.c Dpiperf-fixes/src/driver/ppc64/pi_itrace.c
--- Dpiperf/src/driver/ppc64/pi_itrace.c 2009-03-03 17:46:50.000000000 -0500
+++ Dpiperf-fixes/src/driver/ppc64/pi_itrace.c 2009-03-12 17:34:10.000000000 -0400
@@ -551,7 +551,7 @@ int ITrace_branch_hook_ss(struct pt_regs
return 1;
}
-
+#ifndef STAP_ITRACE // BODY
//
// write_load_store_trace()
// ***********************
@@ -671,6 +671,7 @@ void write_load_store_trace(struct pt_re
per_cpu_data[cpu].prev_sdar = sdar;
}
}
+#endif // STAP_ITRACE BODY
//
// scan_for_new_pids()
diff -paur Dpiperf/src/stap/itrace.1 Dpiperf-fixes/src/stap/itrace.1
--- Dpiperf/src/stap/itrace.1 2009-03-03 17:44:06.000000000 -0500
+++ Dpiperf-fixes/src/stap/itrace.1 2009-03-12 18:19:12.000000000 -0400
@@ -114,7 +114,7 @@ If using with --pid option:
- check dmesg to wait for SystemTap informational message
- continue program to be traced (if necessary)
- hit ^C to terminate systemtap session when done tracing
- (^C is not necessary if using --debuginfo option
+ (^C is not necessary if using --debuginfo option)
temp file directory= /tmp/itraceFJDu2O
diff -paur Dpiperf/src/stap/itrace.c Dpiperf-fixes/src/stap/itrace.c
--- Dpiperf/src/stap/itrace.c 2009-03-03 17:44:06.000000000 -0500
+++ Dpiperf-fixes/src/stap/itrace.c 2009-03-12 18:18:48.000000000 -0400
@@ -266,7 +266,7 @@ void run_stap(void)
else
snprintf(argument, PATH_MAX + 3, "-c %s", prog);
- printf("stap -g %s %s -o %s\n",
+ printf("stap -g %s %s -o %s",
argument, generated_stap_file, output_name);
argv[arg_number++] = "stap";
argv[arg_number++] = "-g";
@@ -282,11 +282,11 @@ void run_stap(void)
argv[arg_number++] = output_name;
for (i=0; i < num_stap_args; i++) {
argv[arg_number + i] = stap_args[i];
- printf("%s ", stap_args[i]);
+ printf(" %s", stap_args[i]);
arg_number++;
}
putchar('\n');
- argv[arg_number + num_stap_args] = 0;
+ argv[arg_number] = NULL;
unlink(output_name);
signal(SIGINT, SIG_DFL);
@@ -295,7 +295,7 @@ void run_stap(void)
printf("- check dmesg to wait for SystemTap informational message");
printf("- continue program to be traced (if necessary)\n");
printf("- hit ^C to terminate systemtap session when done tracing\n");
- printf("\t(^C is not necessary if using --debuginfo option\n");
+ printf("\t(^C is not necessary if using --debuginfo option)\n");
fflush(stdout);
if (execvp("stap", argv) < 0) {
perror("stap");
diff -paur Dpiperf/src/stap/pi_itrace.template Dpiperf-fixes/src/stap/pi_itrace.template
--- Dpiperf/src/stap/pi_itrace.template 2009-03-03 17:44:06.000000000 -0500
+++ Dpiperf-fixes/src/stap/pi_itrace.template 2009-03-13 19:08:08.000000000 -0400
@@ -143,14 +143,17 @@ int printk_binary (int cpu, uint8_t * ra
return 1;
}
+struct write_buf {
+ uint8_t Buffer[PAGE_SIZE];
+};
+struct write_buf pi_write_buf[PI_NR_CPUS];
int SoftTraceRawWrite (uint8_t * rawData, uint16_t rawDataLen, int trace_type)
{
PERFHEADER *PerfHeader = 0;
- uint8_t Buffer[PAGE_SIZE];
- uint8_t *pBuffer = Buffer;
unsigned long flags;
union rdval temps;
int cpu = smp_processor_id();
+ uint8_t *pBuffer = pi_write_buf[cpu].Buffer;
local_irq_save(flags);
@@ -192,8 +195,7 @@ void pi_itrace_cleanup(void)
int i;
unsigned char tempBuf[BUFFER_WRITE_CHUNK_SIZE];
- on_each_cpu(btrace_get_end_time, 0, 1, 1);
-
+ PI_ON_EACH_CPU(btrace_get_end_time, 0, 1);
for (i = 0; i < driver_info.num_cpus; i++) {
unsigned char tempBuf[BUFFER_WRITE_CHUNK_SIZE];
PERFHEADER *PerfBuf = (PERFHEADER *)ptr_btrace_buffers[i];
diff -paur Dpiperf/src/stap/ppc_pi_itrace.template Dpiperf-fixes/src/stap/ppc_pi_itrace.template
--- Dpiperf/src/stap/ppc_pi_itrace.template 2009-03-03 17:44:06.000000000 -0500
+++ Dpiperf-fixes/src/stap/ppc_pi_itrace.template 2009-03-12 15:45:01.000000000 -0400
@@ -26,6 +26,8 @@
[DEFS]
#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,18)
+#undef PDEBUG
+#define PDEBUG(fmt, args...) do {} while (0)
#define GET_VSID(addr) (REGION_ID(addr) >= KERNEL_REGION_ID) ? \
get_kernel_vsid(addr, MMU_SEGSIZE_256M) : \
get_vsid(current->mm->context.id, addr, MMU_SEGSIZE_256M)
stapitrace-build-fixes.patch:
--- NEW FILE stapitrace-build-fixes.patch ---
diff -paur Dpiperf-orig/src/Makefile.am Dpiperf-update/src/Makefile.am
--- Dpiperf-orig/src/Makefile.am 2009-04-03 15:59:52.000000000 -0400
+++ Dpiperf-update/src/Makefile.am 2009-04-03 16:00:17.000000000 -0400
@@ -26,6 +26,14 @@ SUBDIRS = \
endif
else
+if build_stap
+
+SUBDIRS = \
+ a2n \
+ post \
+ stap
+else
+
SUBDIRS = \
perfutil \
wbirlog \
@@ -45,3 +53,4 @@ SUBDIRS = \
wrappers
endif
endif
+endif
diff -paur Dpiperf-orig/src/stap/Makefile.am Dpiperf-update/src/stap/Makefile.am
--- Dpiperf-orig/src/stap/Makefile.am 2009-04-03 10:18:44.000000000 -0400
+++ Dpiperf-update/src/stap/Makefile.am 2009-04-03 16:03:29.000000000 -0400
@@ -4,11 +4,13 @@ if pi_ppc64
AM_CFLAGS = -D__USE_GNU
-noinst_PROGRAMS = stap_filter itrace
+noinst_PROGRAMS = stap_filter
stap_filter_SOURCES = \
stap_filter.c
+bin_PROGRAMS = itrace
+
itrace_SOURCES = \
itrace.c
@@ -17,10 +19,6 @@ BUILT_SOURCES = \
pi_itrace.stp \
ppc_pi_itrace.stp
-itrace: itrace.c
- $(CC) itrace.c -o itrace
-
-
CLEANFILES = ${BUILT_SOURCES}
pi_itrace.stp: stap_filter pi_itrace.template pi_itrace.order
stapitrace-insn-update.patch:
--- NEW FILE stapitrace-insn-update.patch ---
diff -paur Dpiperf/src/stap/itrace.c Dpiperf-update/src/stap/itrace.c
--- Dpiperf/src/stap/itrace.c 2009-03-24 18:30:15.000000000 -0400
+++ Dpiperf-update/src/stap/itrace.c 2009-03-29 11:38:03.000000000 -0400
@@ -403,7 +403,7 @@ FPF("\n");
FPF("\n");
for (i=0; i < num_funcs; i++) {
-FPF1("probe process(\"%s\").itrace if (itrace_on) ", prog);
+FPF1("probe process(\"%s\").insn if (itrace_on) ", prog);
FPF("{\n");
FPF(" pi_trace_it()\n");
FPF("}\n");
Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/stapitrace/devel/.cvsignore,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- .cvsignore 2 Apr 2009 17:56:26 -0000 1.3
+++ .cvsignore 8 Apr 2009 17:08:51 -0000 1.4
@@ -1 +1 @@
-stapitrace-2.0.1.20090402cvs_alpha.tar.gz
+stapitrace-2.0.0.20090304cvs_alpha.tar.gz
Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/stapitrace/devel/sources,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- sources 2 Apr 2009 17:56:26 -0000 1.4
+++ sources 8 Apr 2009 17:08:51 -0000 1.5
@@ -1 +1 @@
-a5302e521d56b148b766acf48e5f6206 stapitrace-2.0.1.20090402cvs_alpha.tar.gz
+ade85ba660fbeee565f458ee5bc1be68 stapitrace-2.0.0.20090304cvs_alpha.tar.gz
Index: stapitrace.spec
===================================================================
RCS file: /cvs/pkgs/rpms/stapitrace/devel/stapitrace.spec,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -r1.25 -r1.26
--- stapitrace.spec 2 Apr 2009 17:56:26 -0000 1.25
+++ stapitrace.spec 8 Apr 2009 17:08:51 -0000 1.26
@@ -2,29 +2,33 @@
# spec file for package itrace
#
-%define alphatag 20090402cvs_alpha
+%define alphatag 20090304cvs_alpha
Name: stapitrace
Summary: Instruction Tracing Tool
-Version: 2.0.1
+Version: 2.0.0
Release: 0.%{alphatag}%{?dist}
License: GPLv2+
Group: Development/Tools
URL: http://sourceforge.net/projects/perfinsp
Source0: %{name}-%{version}.%{alphatag}.tar.gz
Patch0: itrace-f11-fixes-private.patch
+Patch1: itrace-f11-fixes_for-upstream.patch
+Patch2: stapitrace-insn-update.patch
+Patch3: itrace-bfd-config.patch
+Patch4: stapitrace-build-fixes.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
Requires: systemtap systemtap-runtime binutils binutils-devel
BuildRequires: binutils binutils-devel autoconf automake zlib-devel
ExclusiveArch: ppc ppc64
%description
-ITrace is a software tracing mechanism that runs on Linux. ITrace traces
+stapitrace is a software tracing mechanism that runs on Linux. ITrace traces
through user application code using the SystemTap user instruction tracing
support and can produce human-readable ASCII output or qtrace output suitable
for analysis by packages, such as the IBM Performance Simulator for Linux
on POWER (simppc).
-It is based on and shares code from PerformanceInspector's ITRACE tool.
+It is based on and shares code from PerformanceInspector's ITrace tool.
%define systap %{_datadir}/systemtap
%define tap %{systap}/tapset
@@ -36,14 +40,22 @@
%prep
%setup -q -n Dpiperf
%patch0 -p1
+%patch1 -p1
+%patch2 -p1
+%patch3 -p1
+%patch4 -p1
%build
autoreconf -i --force
-# override -m64
export CFLAGS="%{__global_cflags} -mminimal-toc"
export CXXFLAGS="%{__global_cflags} -mminimal-toc"
-%configure --enable-build_stap=yes --enable-lib32on64 --disable-dependency-tracking
+%ifarch ppc
+%configure --enable-build_stap=yes --enable-lib32on64
+%else
+%configure --enable-build_stap=yes
+%endif
+
%{__make} DESTDIR=""
%install
@@ -77,6 +89,10 @@
%{_bindir}/itrace
%changelog -n itrace
+* Wed Apr 08 2009 Maynard Johnson <maynardj at us.ibm.com>
+- Fix build problems; rebase on earlier Performance Inspector
+ CVS snapshot to align with RHEL upstream code deadline
+
* Wed Mar 11 2009 Maynard Johnson <maynardj at us.ibm.com>
- Change to using Systemtap's built-in itrace probe point
- Previous message (by thread): rpms/gnome-bluetooth/devel .cvsignore, 1.11, 1.12 gnome-bluetooth.spec, 1.65, 1.66 sources, 1.12, 1.13 sendto-connect-fix.patch, 1.1, NONE
- Next message (by thread): rpms/amarok/devel amarok-2.0.2-fix_lastfm_auth.patch, NONE, 1.1 amarok.spec, 1.144, 1.145
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-extras-commits
mailing list