<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Converting Real numbers with IEEE format to G_Float format in Operating System - OpenVMS</title>
    <link>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161520#M14375</link>
    <description>We have gone through the same thing.  It's a pain but it works.  We tried to convince Oracle to continue supporting G_Float but that was a lost cause.&lt;BR /&gt;&lt;BR /&gt;It's not the database it's the Oracle client that changed.  The numbers already get converted from some Oracle format to IEEE.  If you use the 9i client on a 10g database you don't have to worry about IEEE conversions.&lt;BR /&gt;&lt;BR /&gt;We can't go totally to IEEE because of DECForms and Codasyl DBMS.  So we went through any code reading or writing to Oracle and added a subroutine to convert the floating point formats.  We controlled it by a logical so it would still work on the Alpha's.  As the other's have said it's a simply LIB$CVT.&lt;BR /&gt;&lt;BR /&gt;On the good side we were able to take an Alpha Oracle 10g database and just copy the datafiles to Integrity.  We found it was easier to migrate Oracle from 9i to 10g on the Alpha side instead of exporting and importing all the data.</description>
    <pubDate>Fri, 14 Mar 2008 20:54:28 GMT</pubDate>
    <dc:creator>Shael Richmond</dc:creator>
    <dc:date>2008-03-14T20:54:28Z</dc:date>
    <item>
      <title>Converting Real numbers with IEEE format to G_Float format</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161516#M14371</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;We are trying to migrate an Oracle application from OpenVMS Alpha to OpenVMS Integrity.&lt;BR /&gt;&lt;BR /&gt;With Oracle on OpenVMS Integrity the real numbers are stored in IEEE format.&lt;BR /&gt;&lt;BR /&gt;All the application code is compiled using G_Float, and we do not want to change this as it will impact on communications with the PLCs.&lt;BR /&gt;&lt;BR /&gt;Is it possible to convert IEEE format numbers to G_Float format numbers easily?&lt;BR /&gt;&lt;BR /&gt;Thanks &lt;BR /&gt;Andrew&lt;BR /&gt;</description>
      <pubDate>Fri, 14 Mar 2008 05:48:09 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161516#M14371</guid>
      <dc:creator>A.W.R</dc:creator>
      <dc:date>2008-03-14T05:48:09Z</dc:date>
    </item>
    <item>
      <title>Re: Converting Real numbers with IEEE format to G_Float format</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161517#M14372</link>
      <description>Andrew,&lt;BR /&gt;&lt;BR /&gt;I64VMS $ help rtl cvt$&lt;BR /&gt;RTL_Routines&lt;BR /&gt;  CVT$&lt;BR /&gt;    Additional information available:&lt;BR /&gt;    CVT$CONVERT_FLOAT     CVT$FTOF&lt;BR /&gt;&lt;BR /&gt;Volker.</description>
      <pubDate>Fri, 14 Mar 2008 06:08:50 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161517#M14372</guid>
      <dc:creator>Volker Halle</dc:creator>
      <dc:date>2008-03-14T06:08:50Z</dc:date>
    </item>
    <item>
      <title>Re: Converting Real numbers with IEEE format to G_Float format</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161518#M14373</link>
      <description>Andrew,&lt;BR /&gt;&lt;BR /&gt;Yes, the conversion can be done in a quite easily and fully supported way.&lt;BR /&gt;&lt;BR /&gt;I completely agree with Volker, the CVT$ routines are the appropriate answer. However, if you are converting significant data, I recommend a careful read through the appropriate manual in the documentation set.&lt;BR /&gt;&lt;BR /&gt;I have done this within applications dynamically for at least one client. There are even faster ways of doing this, but doing it safely requires knowing the ranges of the input/output data.&lt;BR /&gt;&lt;BR /&gt;An important question to ask at this point is: Is the floating point format truly relevant to the PLCs? Or is the data actually just converted to text at some later point. &lt;BR /&gt;&lt;BR /&gt;It may be a piece of missing context, but there may not be a need to preserve the G_Float in this situation. In general, since all of the code will be recompiled in any event, why is there a need to preserve the G-float?&lt;BR /&gt;&lt;BR /&gt;I will put it another way. If the code is inherently sensitive to low-order precision issues between IEEE T and VAX G, then a more careful review of the code prior to switching platforms is recommended (such a sensitivity is not common, but it can exist).&lt;BR /&gt;&lt;BR /&gt;- Bob Gezelter, &lt;A href="http://www.rlgsc.com" target="_blank"&gt;http://www.rlgsc.com&lt;/A&gt;</description>
      <pubDate>Fri, 14 Mar 2008 09:35:23 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161518#M14373</guid>
      <dc:creator>Robert Gezelter</dc:creator>
      <dc:date>2008-03-14T09:35:23Z</dc:date>
    </item>
    <item>
      <title>Re: Converting Real numbers with IEEE format to G_Float format</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161519#M14374</link>
      <description>I'd focus not on the database here, as that component of this conversion is fairly easy and fairly controlled and controllable.  You'll have that solved in fairly short order.&lt;BR /&gt;&lt;BR /&gt;(For instance: you might be able to do an XML export, and then an XML import for the conversion.  Or yes, you can roll your own conversion code and call the cvt$ routines.  This if you want to rebuild and reset and re-organize the internal database structures and contents yourself.)&lt;BR /&gt;&lt;BR /&gt;The "fun" here is probably going to be the PLC.    These widgets tend to be far more persnickety than typical OpenVMS or Oracle code.&lt;BR /&gt;&lt;BR /&gt;You're probably looking to preserve the code operating in the PLC, which means you'll be performing on-the-fly conversions to chat with the device.  (Been there, done that.  Communications with the older PLC iron is particularly "fun".)&lt;BR /&gt;&lt;BR /&gt;IEEE T Float to VAX G Float will incur some processing overhead, though the PLCs tend to be yet slower.   And between the database and the faster processors typical of Itanium, I'd tend to doubt you'll see any conversion-related slow-down here.&lt;BR /&gt;&lt;BR /&gt;Where you'll want to take great care is with the precision; differences in the low-order bits of the converted values, either way.  This can cause match-equal applications tests and some regressions to fail, and it can cause the PLC to be confused.&lt;BR /&gt;&lt;BR /&gt;Do you have the original ladder-logic or whatever the source code was loaded into the PLCs?  (I know you don't want to convert your PLC "firmware", but you should take a look at it and see what it's actually doing with the FP values, and if slight changes in precision will send it "off the rails".)&lt;BR /&gt;&lt;BR /&gt;The other thing you will want to look at -- and I'm recalling my days dealing with PLCs, and what you had to do -- is a careful look for alignment faults.  Some of the code constructions that can be used to interface with PLCs might well generate these, and these faults can be a performance nightmare on Itanium when they arise in sufficient quantities.  See other discussions of alignment faults, or most any OpenVMS I64 performance discussion for details.&lt;BR /&gt;&lt;BR /&gt;(And yes, there's some overlap here and over in comp.os.vms.  The OpenVMS community isn't that large.)&lt;BR /&gt;&lt;BR /&gt;Stephen Hoffman&lt;BR /&gt;HoffmanLabs LLC&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Fri, 14 Mar 2008 13:12:13 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161519#M14374</guid>
      <dc:creator>Hoff</dc:creator>
      <dc:date>2008-03-14T13:12:13Z</dc:date>
    </item>
    <item>
      <title>Re: Converting Real numbers with IEEE format to G_Float format</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161520#M14375</link>
      <description>We have gone through the same thing.  It's a pain but it works.  We tried to convince Oracle to continue supporting G_Float but that was a lost cause.&lt;BR /&gt;&lt;BR /&gt;It's not the database it's the Oracle client that changed.  The numbers already get converted from some Oracle format to IEEE.  If you use the 9i client on a 10g database you don't have to worry about IEEE conversions.&lt;BR /&gt;&lt;BR /&gt;We can't go totally to IEEE because of DECForms and Codasyl DBMS.  So we went through any code reading or writing to Oracle and added a subroutine to convert the floating point formats.  We controlled it by a logical so it would still work on the Alpha's.  As the other's have said it's a simply LIB$CVT.&lt;BR /&gt;&lt;BR /&gt;On the good side we were able to take an Alpha Oracle 10g database and just copy the datafiles to Integrity.  We found it was easier to migrate Oracle from 9i to 10g on the Alpha side instead of exporting and importing all the data.</description>
      <pubDate>Fri, 14 Mar 2008 20:54:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161520#M14375</guid>
      <dc:creator>Shael Richmond</dc:creator>
      <dc:date>2008-03-14T20:54:28Z</dc:date>
    </item>
    <item>
      <title>Re: Converting Real numbers with IEEE format to G_Float format</title>
      <link>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161521#M14376</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Thank you all for your time and responses. &lt;BR /&gt;&lt;BR /&gt;It is really appreciated to receive advice from those that there have come across similar issues.&lt;BR /&gt;&lt;BR /&gt;I am never sure where is the best place to post these type of queries. &lt;BR /&gt;&lt;BR /&gt;I did post these as well on the Oracle forum, but got no response.&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;BR /&gt;Andrew</description>
      <pubDate>Mon, 17 Mar 2008 05:59:15 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-openvms/converting-real-numbers-with-ieee-format-to-g-float-format/m-p/4161521#M14376</guid>
      <dc:creator>A.W.R</dc:creator>
      <dc:date>2008-03-17T05:59:15Z</dc:date>
    </item>
  </channel>
</rss>

