Skip to content

ROMIO

  • ROMIO: A High-Performance, Portable MPI-IO Implementation

helpful GDB macro

August 7, 2014 by Latham, Robert J.

The fundamental data structure in ROMIO is the “flattened representation” of a dataype: this list of  “offset-length” pairs describes any MPI datatype, if perhaps at the cost of memory and computational overhead.  For years I have been linking in little utility functions to dump out these lists.  Turns out GDB macros can do this for me.  I added this to my .gdbinit:

define dump_flattened
set $flat = $arg0
set $i = 0
while $i < $flat->count
printf "(%ld, %ld)", $flat->indices[$i], $flat->blocklens[$i]
set $i = $i + 1
end
printf "\n"
end
document dump_flattened
Display ROMIO flattened representations (offset-length pairs) of datatypes
example usage: dump_flattened flat_type
end

then in gdb I can simply invoke ‘dump_flattened’ on the flat list node:

(gdb) p flat_buf
$1 = (ADIOI_Flatlist_node *) 0x638b68
(gdb) dump_flattened flat_buf
(0, 1296)(0, 1296)(0, 1296)

Hopefully future ROMIO hackers will benefit from this sooner than I did.
(note: an earlier version of this post had a bug in it that did not increment the blocklens[] index)

Post navigation

Previous Post:

More headaches with 2 GiB I/O

Next Post:

ROMIO changes in MPICH-3.1.3

Recent Posts

  • ROMIO and MPICH-4.3.0
  • ROMIO and “large counts”
  • Hintdump: a small utility for poking at MPI implementations.
  • Quobyte file system
  • ROMIO at SC 2019

Recent Comments

  • ROMIO » New ROMIO optimizations for Blue Gene /Q on bglockless
  • bglockless | ROMIO on New ROMIO optimizations for Blue Gene /Q

Archives

  • February 2025
  • May 2024
  • April 2023
  • October 2020
  • November 2019
  • February 2019
  • December 2018
  • November 2018
  • September 2018
  • November 2017
  • September 2017
  • March 2017
  • August 2016
  • June 2016
  • January 2016
  • December 2015
  • November 2015
  • June 2015
  • May 2015
  • February 2015
  • October 2014
  • August 2014
  • July 2014
  • June 2014
  • August 2013
  • July 2013
  • February 2012
  • September 2010
  • November 2009
  • November 2008
  • September 2008
  • February 2006
  • August 2003
  • February 2002

Categories

  • development
  • features
  • gpfs
  • intel-mpi
  • lustre
  • presentations
  • publications
  • releases
  • tuning
  • Uncategorized

Meta

  • Log in
  • Entries feed
  • Comments feed
  • WordPress.org
© 2025 ROMIO | WordPress Theme by Superbthemes