PGI 5 User's Guide

Total Page:16

File Type:pdf, Size:1020Kb

PGI 5 User's Guide PGI® User’s Guide Parallel Fortran, C and C++ for Scientists and Engineers The Portland Group™ STMicroelectronics 9150 SW Pioneer Court, Suite H Wilsonville, OR 97070 While every precaution has been taken in the preparation of this document, The Portland Group™, a wholly-owned subsidiary of STMicroelectronics, makes no warranty for the use of its products and assumes no responsibility for any errors that may appear, or for damages resulting from the use of the information contained herein. The Portland Group retains the right to make changes to this information at any time, without notice. The software described in this document is distributed under license from STMicroelectronics and may be used or copied only in accordance with the terms of the license agreement. No part of this document may be reproduced or transmitted in any form or by any means, for any purpose other than the purchaser's personal use without the express written permission of The Portland Group. Many of the designations used by manufacturers and sellers to distinguish their products are claimed as trademarks. Where those designations appear in this manual, The Portland Group was aware of a trademark claim. The designations have been printed in caps or initial caps. Thanks is given to the Parallel Tools Consortium and, in particular, to the High Performance Debugging Forum for their efforts. PGF95, PGF95, PGC++, Cluster Development Kit, CDK and The Portland Group are trademarks and PGI, PGHPF, PGF77, PGCC, PGPROF, and PGDBG are registered trademarks of STMicroelectronics, Inc. Other brands and names are the property of their respective owners. The use of STLport, a C++ Library, is licensed separately and license, distribution and copyright notice can be found in the online documentation for a given release of the PGI compilers and tools. PGI User's Guide Copyright © 1998 – 2000, The Portland Group, Inc. Copyright © 2000 – 2005, STMicroelectronics, Inc. All rights reserved. Printed in the United States of America Part Number: 2030-990-888-0603 First Printing: Release 1.7, June 1998 Second Printing: Release 3.0, January 1999 Third Printing: Release 3.1, September 1999 Fourth Printing: Release 3.2, September 2000 Fifth Printing: Release 4.0, May 2002 Sixth Printing: Release 5.0, June 2003 Seventh Printing: Release 5.1, November 2003 Eighth Printing Release 5.2, June 2004 Ninth Printing Release 6.0, March 2005 Technical support: [email protected] Sales: [email protected] Web: http://www.pgroup.com/ Table of Contents PREFACE........................................................................................................................................1 AUDIENCE DESCRIPTION................................................................................................................1 COMPATIBILITY AND CONFORMANCE TO STANDARDS...................................................................1 ORGANIZATION..............................................................................................................................2 HARDWARE AND SOFTWARE CONSTRAINTS ..................................................................................3 CONVENTIONS ...............................................................................................................................4 RELATED PUBLICATIONS ...............................................................................................................6 GETTING STARTED ....................................................................................................................7 1.1 OVERVIEW ...............................................................................................................................7 1.2 INVOKING THE COMMAND-LEVEL PGI COMPILERS..................................................................8 1.2.1 Command-line Syntax......................................................................................................8 1.2.2 Command-line Options ....................................................................................................9 1.2.3 Fortran Directives and C/C++ Pragmas ..........................................................................9 1.3 FILENAME CONVENTIONS ......................................................................................................10 1.3.1 Input Files ......................................................................................................................10 1.3.2 Output Files....................................................................................................................11 1.4 PARALLEL PROGRAMMING USING THE PGI COMPILERS ........................................................13 1.4.1 Running SMP Parallel Programs....................................................................................13 1.4.2 Running Data Parallel HPF Programs............................................................................14 1.5 USING THE PGI COMPILERS ON LINUX...................................................................................15 1.5.1 Linux Header Files.........................................................................................................15 1.5.2 Running Parallel Programs on Linux .............................................................................16 Table of Contents iii 1.6 USING THE PGI COMPILERS ON WINDOWS ............................................................................ 16 OPTIMIZATION & PARALLELIZATION ............................................................................. 19 2.1 OVERVIEW OF OPTIMIZATION................................................................................................ 19 2.2 GETTING STARTED WITH OPTIMIZATIONS.............................................................................. 21 2.3 LOCAL AND GLOBAL OPTIMIZATION USING −O .................................................................... 23 2.3.1 Scalar SSE Code Generation.......................................................................................... 25 2.4 LOOP UNROLLING USING −MUNROLL ................................................................................... 25 2.5 VECTORIZATION USING −MVECT .......................................................................................... 27 2.5.1 Vectorization Sub-options ............................................................................................. 27 2.5.1.1 Assoc Option........................................................................................................... 28 2.5.1.2 Cachesize Option .................................................................................................... 28 2.5.1.3 SSE Option ............................................................................................................. 28 2.5.1.4 Prefetch Option....................................................................................................... 29 2.5.2 Vectorization Example Using SSE/SSE2 Instructions................................................... 29 2.6 AUTO-PARALLELIZATION USING −MCONCUR ....................................................................... 32 2.6.1 Auto-parallelization Sub-options ................................................................................... 33 2.6.1.1 Altcode Option........................................................................................................ 33 2.6.1.2 Dist Option.............................................................................................................. 33 2.6.1.3 Cncall Option.......................................................................................................... 33 2.6.2 Auto-parallelization Example ........................................................................................ 34 2.6.3 Loops That Fail to Parallelize ........................................................................................ 35 2.6.3.1 Timing Loops.......................................................................................................... 35 2.6.3.2 Scalars..................................................................................................................... 35 2.6.3.3 Scalar Last Values................................................................................................... 36 2.7 INTER-PROCEDURAL ANALYSIS AND OPTIMIZATION USING -MIPA........................................ 38 iv Table of Contents 2.7.1 Building a Program Without IPA – Single Step.............................................................38 2.7.2 Building a Program Without IPA - Several Steps..........................................................38 2.7.3 Building a Program Without IPA Using Make ..............................................................39 2.7.4 Building a Program with IPA.........................................................................................39 2.7.5 Building a Program with IPA - Single Step ...................................................................40 2.7.6 Building a Program with IPA - Several Steps................................................................41 2.7.7 Building a Program with IPA Using Make ....................................................................42 2.7.8 Questions about IPA ......................................................................................................42 2.8 DEFAULT OPTIMIZATION LEVELS ..........................................................................................43 2.9 LOCAL OPTIMIZATION USING DIRECTIVES
Recommended publications
  • Mipspro C++ Programmer's Guide
    MIPSproTM C++ Programmer’s Guide 007–0704–150 CONTRIBUTORS Rewritten in 2002 by Jean Wilson with engineering support from John Wilkinson and editing support from Susan Wilkening. COPYRIGHT Copyright © 1995, 1999, 2002 - 2003 Silicon Graphics, Inc. All rights reserved; provided portions may be copyright in third parties, as indicated elsewhere herein. No permission is granted to copy, distribute, or create derivative works from the contents of this electronic documentation in any manner, in whole or in part, without the prior written permission of Silicon Graphics, Inc. LIMITED RIGHTS LEGEND The electronic (software) version of this document was developed at private expense; if acquired under an agreement with the USA government or any contractor thereto, it is acquired as "commercial computer software" subject to the provisions of its applicable license agreement, as specified in (a) 48 CFR 12.212 of the FAR; or, if acquired for Department of Defense units, (b) 48 CFR 227-7202 of the DoD FAR Supplement; or sections succeeding thereto. Contractor/manufacturer is Silicon Graphics, Inc., 1600 Amphitheatre Pkwy 2E, Mountain View, CA 94043-1351. TRADEMARKS AND ATTRIBUTIONS Silicon Graphics, SGI, the SGI logo, IRIX, O2, Octane, and Origin are registered trademarks and OpenMP and ProDev are trademarks of Silicon Graphics, Inc. in the United States and/or other countries worldwide. MIPS, MIPS I, MIPS II, MIPS III, MIPS IV, R2000, R3000, R4000, R4400, R4600, R5000, and R8000 are registered or unregistered trademarks and MIPSpro, R10000, R12000, R1400 are trademarks of MIPS Technologies, Inc., used under license by Silicon Graphics, Inc. Portions of this publication may have been derived from the OpenMP Language Application Program Interface Specification.
    [Show full text]
  • CRTE V11.1A Common Runtime Environment
    English FUJITSU Software BS2000 CRTE V11.1A Common Runtime Environment User Guide * Edition December 2019 Comments… Suggestions… Corrections… The User Documentation Department would like to know your opinion on this manual. Your feedback helps us to optimize our documentation to suit your individual needs. Feel free to send us your comments by e-mail to: [email protected] senden. Certified documentation according to DIN EN ISO 9001:2015 To ensure a consistently high quality standard and user-friendliness, this documentation was created to meet the regulations of a quality management system which complies with the requirements of the standard DIN EN ISO 9001:2015 . Copyright and Trademarks Copyright © 2019 Fujitsu Technology Solutions GmbH. All rights reserved. Delivery subject to availability; right of technical modifications reserved. All hardware and software names used are trademarks of their respective manufacturers. Table of Contents CRTE V11.1 . 6 1 Preface . 7 1.1 Objectives and target groups of this manual . 8 1.2 Summary of contents . 9 1.3 Changes since the last edition of the manual . 10 1.4 Notational conventions . 11 2 Selectable unit, installation and shareability of CRTE . 12 2.1 CRTE V11.1A selectable unit . 13 2.2 Installing CRTE . 16 2.2.1 CRTE libraries for installation without version specification . 17 2.2.2 Standard installation under the user ID “$.” . 18 2.2.3 Installing with IMON under a non-standard user ID . 19 2.2.4 Installing header files and POSIX link switches in the default POSIX directory . 20 2.2.5 Installing header files and POSIX link switches in any POSIX directory .
    [Show full text]
  • PGI Fortran Guide
    PGI® User’s Guide Parallel Fortran, C and C++ for Scientists and Engineers The Portland Group® STMicroelectronics Two Centerpointe Drive Lake Oswego, OR 97035 While every precaution has been taken in the preparation of this document, The Portland Group® (PGI®), a wholly-owned subsidiary of STMicroelectronics, Inc., makes no warranty for the use of its products and assumes no responsibility for any errors that may appear, or for damages resulting from the use of the information contained herein. The Portland Group ® retains the right to make changes to this information at any time, without notice. The software described in this document is distributed under license from STMicroelectronics, Inc. and/or The Portland Group® and may be used or copied only in accordance with the terms of the license agreement ("EULA"). No part of this document may be reproduced or transmitted in any form or by any means, for any purpose other than the purchaser's or the end user's personal use without the express written permission of STMicroelectronics, Inc and/or The Portland Group®. Many of the designations used by manufacturers and sellers to distinguish their products are claimed as trademarks. Where those designations appear in this manual, STMicroelectronics was aware of a trademark claim. The designations have been printed in caps or initial caps. PGF95, PGF90, and PGI Unified Binary are trademarks; and PGI, PGHPF, PGF77, PGCC, PGC++, PGI Visual Fortran, PVF, Cluster Development Kit, PGPROF, PGDBG, and The Portland Group are registered trademarks of The Portland Group Incorporated. PGI CDK is a registered trademark of STMicroelectronics. *Other brands and names are the property of their respective owners.
    [Show full text]
  • The Portland Group
    ® PGI Compiler User's Guide Parallel Fortran, C and C++ for Scientists and Engineers Release 2011 The Portland Group While every precaution has been taken in the preparation of this document, The Portland Group® (PGI®), a wholly-owned subsidiary of STMicroelectronics, Inc., makes no warranty for the use of its products and assumes no responsibility for any errors that may appear, or for damages resulting from the use of the information contained herein. The Portland Group retains the right to make changes to this information at any time, without notice. The software described in this document is distributed under license from STMicroelectronics and/or The Portland Group and may be used or copied only in accordance with the terms of the end-user license agreement ("EULA"). PGI Workstation, PGI Server, PGI Accelerator, PGF95, PGF90, PGFORTRAN, and PGI Unified Binary are trademarks; and PGI, PGHPF, PGF77, PGCC, PGC++, PGI Visual Fortran, PVF, PGI CDK, Cluster Development Kit, PGPROF, PGDBG, and The Portland Group are registered trademarks of The Portland Group Incorporated. Other brands and names are property of their respective owners. No part of this document may be reproduced or transmitted in any form or by any means, for any purpose other than the purchaser's or the end user's personal use without the express written permission of STMicroelectronics and/or The Portland Group. PGI® Compiler User’s Guide Copyright © 2010-2011 STMicroelectronics, Inc. All rights reserved. Printed in the United States of America First Printing: Release 2011, 11.0, December, 2010 Second Printing: Release 2011, 11.1, January, 2011 Third Printing: Release 2011, 11.2, February, 2011 Fourth Printing: Release 2011, 11.3, March, 2011 Fourth Printing: Release 2011, 11.4, April, 2011 Technical support: [email protected] Sales: [email protected] Web: www.pgroup.com ID: 1196151 Contents Preface .....................................................................................................................................
    [Show full text]
  • The Portland Group
    ® PGI Compiler Reference Manual Parallel Fortran, C and C++ for Scientists and Engineers Release 2011 The Portland Group While every precaution has been taken in the preparation of this document, The Portland Group® (PGI®), a wholly-owned subsidiary of STMicroelectronics, Inc., makes no warranty for the use of its products and assumes no responsibility for any errors that may appear, or for damages resulting from the use of the information contained herein. The Portland Group retains the right to make changes to this information at any time, without notice. The software described in this document is distributed under license from STMicroelectronics and/or The Portland Group and may be used or copied only in accordance with the terms of the end-user license agreement ("EULA"). PGI Workstation, PGI Server, PGI Accelerator, PGF95, PGF90, PGFORTRAN, and PGI Unified Binary are trademarks; and PGI, PGHPF, PGF77, PGCC, PGC++, PGI Visual Fortran, PVF, PGI CDK, Cluster Development Kit, PGPROF, PGDBG, and The Portland Group are registered trademarks of The Portland Group Incorporated. Other brands and names are property of their respective owners. No part of this document may be reproduced or transmitted in any form or by any means, for any purpose other than the purchaser's or the end user's personal use without the express written permission of STMicroelectronics and/or The Portland Group. PGI® Compiler Reference Manual Copyright © 2010-2011 STMicroelectronics, Inc. All rights reserved. Printed in the United States of America First printing: Release 2011, 11.0, December, 2010 Second Printing: Release 2011, 11.1, January 2011 Third Printing: Release 2011, 11.3, March 2011 Fourth Printing: Release 2011, 11.4, April 2011 Fifth Printing: Release 2011, 11.5, May 2011 Technical support: [email protected] Sales: [email protected] Web: www.pgroup.com ID: 111162228 Contents Preface .....................................................................................................................................
    [Show full text]
  • The Portland Group
    PGI Visual Fortran® 2013 Installation Guide Version 13.5 The Portland Group While every precaution has been taken in the preparation of this document, The Portland Group® (PGI®), a wholly-owned subsidiary of STMicroelectronics, Inc., makes no warranty for the use of its products and assumes no responsibility for any errors that may appear, or for damages resulting from the use of the information contained herein. The Portland Group retains the right to make changes to this information at any time, without notice. The software described in this document is distributed under license from STMicroelectronics and/or The Portland Group and may be used or copied only in accordance with the terms of the license agreement ("EULA"). PGI Workstation, PGI Server, PGI Accelerator, PGF95, PGF90, PGFORTRAN, and PGI Unified Binary are trademarks; and PGI, PGHPF, PGF77, PGCC, PGC++, PGI Visual Fortran, PVF, PGI CDK, Cluster Development Kit, PGPROF, PGDBG, and The Portland Group are registered trademarks of The Portland Group Incorporated. Other brands and names are property of their respective owners. No part of this document may be reproduced or transmitted in any form or by any means, for any purpose other than the purchaser's or the end user's personal use without the express written permission of STMicroelectronics and/or The Portland Group. PVF® Installation Guide Copyright © 2010-2013 STMicroelectronics, Inc. All rights reserved. Printed in the United States of America First Printing: Release 2013, version 13.1, January 2013 Second Printing: Release 2013, version 13.2, February 2013 Third Printing: Release 2013, version 13.3, March 2013 Fourth Printing: Release 2013, version 13.4, April 2013 Fourth Printing: Release 2013, version 13.5, May 2013 Technical support: [email protected] Sales: [email protected] Web: www.pgroup.com ID: 07183206 Contents 1.
    [Show full text]
  • The Portland Group
    PGI® 2013 Release Notes Version 13.3 The Portland Group While every precaution has been taken in the preparation of this document, The Portland Group® (PGI®) makes no warranty for the use of its products and assumes no responsibility for any errors that may appear, or for damages resulting from the use of the information contained herein. The Portland Group retains the right to make changes to this information at any time, without notice. The software described in this document is distributed under license from The Portland Group and/or its licensors and may be used or copied only in accordance with the terms of the end-user license agreement ("EULA"). PGI Workstation, PGI Server, PGI Accelerator, PGF95, PGF90, PGFORTRAN, PGI Unified Binary, and PGCL are trademarks; and PGI, PGHPF, PGF77, PGCC, PGC++, PGI Visual Fortran, PVF, PGI CDK, Cluster Development Kit, PGPROF, PGDBG, and The Portland Group are registered trademarks of The Portland Group Incorporated. Other brands and names are property of their respective owners. No part of this document may be reproduced or transmitted in any form or by any means, for any purpose other than the purchaser's or the end user's personal use without the express written permission of The Portland Group, Inc. PGI® 2013 Release Notes Copyright © 2013 The Portland Group, Inc. and STMicroelectronics, Inc. All rights reserved. Printed in the United States of America First Printing: Release 2013, version 13.1, January 2013 Second Printing: Release 2013, version 13.2, February 2013 Third Printing: Release 2013, version 13.3, March 2013 Technical support: [email protected] Sales: [email protected] Web: www.pgroup.com ID: 07135184 Contents 1.
    [Show full text]
  • Tuning C++ Applications for the Latest Generation X64 Processors with PGI Compilers and Tools
    Tuning C++ Applications for the Latest Generation x64 Processors with PGI Compilers and Tools Douglas Doerfler and David Hensinger Sandia National Laboratories Brent Leback and Douglas Miles The Portland Group (PGI) ABSTRACT: At CUG 2006, a cache oblivious implementation of a two dimensional Lagrangian hydrodynamics model of a single ideal gas material was presented. This paper presents further optimizations to this C++ application to allow packed, consecutive-element storage of vectors, some restructuring of loops containing neighborhood operations, and adding type qualifiers to some C++ pointer declarations to improve performance. In addition to restructuring of the application, analysis of the compiler-generated code resulted in improvements to the latest PGI C++ compiler in the area of loop-carried redundancy elimination, resolution of pointer aliasing conflicts, and vectorization of loops containing min and max reductions. These restructuring and compiler optimization efforts by PGI and Sandia have resulted in application speedups of 1.25 to 1.80 on the latest generation of x64 processors. KEYWORDS: Compiler, C, C++, Optimization, Vectorization, Performance Analysis, AMD Opteron™, Intel Core™ 2, Micro-architecture vector or SIMD units to increase FLOP rates in general 1. Introduction purpose processors. While first-generation AMD and Intel 64-bit x86 Although modern compilers do an admirable job of (x64) processors contain 128-bit wide Streaming SIMD optimization when provided with nothing other than the Extensions (SSE) registers, their 64-bit data paths and “–fast” switch, many times there are still significant floating-point units limit the performance benefit of performance gains to be obtained with detailed analysis vectorizing double-precision loops.
    [Show full text]
  • Supercomputing in Plain English Exercise #3: Arithmetic Operations in This Exercise, We’Ll Use the Same Conventions and Commands As in Exercises #1 and #2
    Supercomputing in Plain English Exercise #3: Arithmetic Operations In this exercise, we’ll use the same conventions and commands as in Exercises #1 and #2. You should refer back to the Exercise #1 and #2 descriptions for details on various Unix commands. You MUST complete Exercises #1 and #2 BEFORE starting Exercise #3. For Exercise #3, YOU ARE EXPECTED TO KNOW HOW TO ACCOMPLISH BASIC TASKS, based on your experiences with Exercises #1 and #2. In the exercise, you’ll benchmark various arithmetic operations, using various compilers and levels of compiler optimization. Specifically, you’ll benchmark using the following compilers: the GNU Fortran compiler, gfortran, for various optimization levels; the Intel Fortran compiler, ifort, for various optimization levels; the Portland Group Fortran compiler, pgf90, for various optimization levels. Here are the steps for this exercise: 1. Log in to the Linux cluster supercomputer (sooner.oscer.ou.edu). 2. Copy the ArithmeticOperations directory: % cp -r ~hneeman/SIPE2011_exercises/ArithmeticOperations/ ~/SIPE2011_exercises/ 3. Choose which language you want to use (C or Fortran90), and cd into the appropriate directory: % cd ~/SIPE2011_exercises/ArithmeticOperations/C/ OR: % cd ~/SIPE2011_exercises/ArithmeticOperations/Fortran90/ 4. Edit the batch script arithmetic_operations.bsub so that it contains your username and your e-mail address. 5. Compile, using the shell script named make_cmd (a shell script is a file containing a sequence of Unix commands), which in turn invokes the make command: % make_cmd If that doesn’t work, try this: % ./make_cmd 6. Submit the batch job: % bsub < arithmetic_operations.bsub 7. Once the batch job completes, examine the several output files to see the timings for your runs with executables created by the various compilers under the various levels of optimization.
    [Show full text]
  • C++ Programmer's Guide
    C++ Programmer’s Guide Document Number 007–0704–130 St. Peter’s Basilica image courtesy of ENEL SpA and InfoByte SpA. Disk Thrower image courtesy of Xavier Berenguer, Animatica. Copyright © 1995, 1999 Silicon Graphics, Inc. All Rights Reserved. This document or parts thereof may not be reproduced in any form unless permitted by contract or by written permission of Silicon Graphics, Inc. LIMITED AND RESTRICTED RIGHTS LEGEND Use, duplication, or disclosure by the Government is subject to restrictions as set forth in the Rights in Data clause at FAR 52.227-14 and/or in similar or successor clauses in the FAR, or in the DOD, DOE or NASA FAR Supplements. Unpublished rights reserved under the Copyright Laws of the United States. Contractor/manufacturer is Silicon Graphics, Inc., 1600 Amphitheatre Pkwy., Mountain View, CA 94043-1351. Autotasking, CF77, CRAY, Cray Ada, CraySoft, CRAY Y-MP, CRAY-1, CRInform, CRI/TurboKiva, HSX, LibSci, MPP Apprentice, SSD, SUPERCLUSTER, UNICOS, X-MP EA, and UNICOS/mk are federally registered trademarks and Because no workstation is an island, CCI, CCMT, CF90, CFT, CFT2, CFT77, ConCurrent Maintenance Tools, COS, Cray Animation Theater, CRAY APP, CRAY C90, CRAY C90D, Cray C++ Compiling System, CrayDoc, CRAY EL, CRAY J90, CRAY J90se, CrayLink, Cray NQS, Cray/REELlibrarian, CRAY S-MP, CRAY SSD-T90, CRAY SV1, CRAY T90, CRAY T3D, CRAY T3E, CrayTutor, CRAY X-MP, CRAY XMS, CRAY-2, CSIM, CVT, Delivering the power . ., DGauss, Docview, EMDS, GigaRing, HEXAR, IOS, ND Series Network Disk Array, Network Queuing Environment, Network Queuing Tools, OLNET, RQS, SEGLDR, SMARTE, SUPERLINK, System Maintenance and Remote Testing Environment, Trusted UNICOS, and UNICOS MAX are trademarks of Cray Research, Inc., a wholly owned subsidiary of Silicon Graphics, Inc.
    [Show full text]
  • PGI Visual Fortran Reference Manual
    ® PGI Visual Fortran Reference Manual Parallel Fortran for Scientists and Engineers Release 2011 The Portland Group While every precaution has been taken in the preparation of this document, The Portland Group® (PGI®), a wholly-owned subsidiary of STMicroelectronics, Inc., makes no warranty for the use of its products and assumes no responsibility for any errors that may appear, or for damages resulting from the use of the information contained herein. The Portland Group retains the right to make changes to this information at any time, without notice. The software described in this document is distributed under license from STMicroelectronics and/or The Portland Group and may be used or copied only in accordance with the terms of the end-user license agreement ("EULA"). PGI Workstation, PGI Server, PGI Accelerator, PGF95, PGF90, PGFORTRAN, and PGI Unified Binary are trademarks; and PGI, PGHPF, PGF77, PGCC, PGC++, PGI Visual Fortran, PVF, PGI CDK, Cluster Development Kit, PGPROF, PGDBG, and The Portland Group are registered trademarks of The Portland Group Incorporated. Other brands and names are property of their respective owners. No part of this document may be reproduced or transmitted in any form or by any means, for any purpose other than the purchaser's or the end user's personal use without the express written permission of STMicroelectronics and/or The Portland Group. PGI® Visual Fortran Reference Manual Copyright © 2010-2012 STMicroelectronics, Inc. All rights reserved. Printed in the United States of America First printing:
    [Show full text]
  • A Customizable, Front-End Retargetablesource Code Analysis
    GENOA - A Customizable, front-end retargetable Source Code Analysis Framework Premkumar T. Devanbu [email protected] Dept. Of Computer Science, University of California, Davis, CA 95616 Code Analysis tools provide support for such software engineering tasks as program understanding, software metrics, testing and re-engineering. In this paper we describe genoa, the framework underlying application generators such as Aria [Devanbu et al. 1996] and gen++ [?] which have been used to generate a wide range of practical code analysis tools. This experience illustrates front-end retargetability of genoa; we describe the features of the genoa framework that allow it to be used with dierent front ends. While permitting arbitrary parse tree computations, the genoa specication language has special, compact iteration operators that are tuned for expressing simple, polynomial time analysis programs; in fact, there is a useful sublanguage of the genoa language that can express precisely all (and only) polynomial time (PTIME) analysis programs on parse-trees. Thus, we argue that the genoa language is a simple and convenient vehicle for implementing a range of analysis tools. We also argue that the “front-end reuse” approach of GENOA oers an important advantage for tools aimed at large software projects: the reuse of complex, expensive build procedures to run generated tools over large source bases. In this paper, we describe the genoa framework and our experiences with it. Categories and Subject Descriptors: D.2.3 [Software Engineering]: Coding Tools and Tech- niques; D.2.6 [Software Engineering]: Programming Environments General Terms: Languages Additional Key Words and Phrases: source analysis, reverse engineering, metrics, code inspection 1.
    [Show full text]