Open MPI logo

Hardware Locality Development Mailing List Archives

  |   Home   |   Support   |   FAQ   |   all Hardware Locality Development mailing list

Subject: [hwloc-devel] XML::Simple doesn't like lstopo's XML
From: Jeff Squyres (jsquyres_at_[hidden])
Date: 2012-11-19 13:01:40


Odd. On the SVN trunk, I'm running this code:

-----
open (LSTOPO, "lstopo -.xml|") || die "Can't open lstopo";
my $lstopo;
while (<LSTOPO>) {
    $lstopo .= $_;
    print "Read: $_";
}
close(LSTOPO);
                                                                                  
my $xml;
$xml = XMLin($lstopo);
print Dumper($xml);
-----

In looking at the output, I see that lstopo's XML output includes all PCI devices, but when I look at the Dumper output of the parsed XML, some PCI devices are not listed. In particular: both eth4 and eth5 are included in the "lstopo -.xml" output, but eth4 is not included in the Dumper output.

The same thing happens if I "lstopo foo.xml" and then "XMLin("foo.xml")". So it's not a problem with perl reading from lstopo's stdout.

I've attached foo.xml -- any ideas why this is happening?

-- 
Jeff Squyres
jsquyres_at_[hidden]
For corporate legal information go to: http://www.cisco.com/web/about/doing_business/legal/cri/