<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://wiki.intellivision.us/index.php?action=history&amp;feed=atom&amp;title=Dividivu.asm</id>
		<title>Dividivu.asm - Revision history</title>
		<link rel="self" type="application/atom+xml" href="http://wiki.intellivision.us/index.php?action=history&amp;feed=atom&amp;title=Dividivu.asm"/>
		<link rel="alternate" type="text/html" href="http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;action=history"/>
		<updated>2026-06-24T20:48:18Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.30.0</generator>

	<entry>
		<id>http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;diff=14780&amp;oldid=prev</id>
		<title>Mr z: Protected &quot;Dividivu.asm&quot; ([edit=autoconfirmed] (indefinite) [move=autoconfirmed] (indefinite))</title>
		<link rel="alternate" type="text/html" href="http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;diff=14780&amp;oldid=prev"/>
				<updated>2010-12-04T08:18:07Z</updated>
		
		<summary type="html">&lt;p&gt;Protected &amp;quot;&lt;a href=&quot;/index.php/Dividivu.asm&quot; title=&quot;Dividivu.asm&quot;&gt;Dividivu.asm&lt;/a&gt;&amp;quot; ([edit=autoconfirmed] (indefinite) [move=autoconfirmed] (indefinite))&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr style=&quot;vertical-align: top;&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 08:18, 4 December 2010&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; style=&quot;text-align: center;&quot; lang=&quot;en&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(No difference)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>Mr z</name></author>	</entry>

	<entry>
		<id>http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;diff=2946&amp;oldid=prev</id>
		<title>Mr z: /* Functions Provided */</title>
		<link rel="alternate" type="text/html" href="http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;diff=2946&amp;oldid=prev"/>
				<updated>2008-09-06T20:50:10Z</updated>
		
		<summary type="html">&lt;p&gt;‎&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;Functions Provided&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr style=&quot;vertical-align: top;&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 20:50, 6 September 2008&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l4&quot; &gt;Line 4:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 4:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;CENTER&amp;gt;&amp;lt;TABLE BORDER&amp;gt;&amp;lt;TR&amp;gt;&amp;lt;TH&amp;gt;Entry point&amp;lt;/TH&amp;gt;&amp;lt;TH&amp;gt;Function provided&amp;lt;/TH&amp;gt;&amp;lt;TH&amp;gt;Notes&amp;lt;/TH&amp;gt;&amp;lt;/TR&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;CENTER&amp;gt;&amp;lt;TABLE BORDER&amp;gt;&amp;lt;TR&amp;gt;&amp;lt;TH&amp;gt;Entry point&amp;lt;/TH&amp;gt;&amp;lt;TH&amp;gt;Function provided&amp;lt;/TH&amp;gt;&amp;lt;TH&amp;gt;Notes&amp;lt;/TH&amp;gt;&amp;lt;/TR&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVI&amp;lt;/TD&amp;gt;&amp;lt;TD ROWSPAN=3&amp;gt;Divide two signed integers / fixed-&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;pt &lt;/del&gt;numbers&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator in register, denominator and fractional point fixed in ROM.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVI&amp;lt;/TD&amp;gt;&amp;lt;TD ROWSPAN=3&amp;gt;Divide two signed integers / &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;[[Fixed Point Arithmetic|&lt;/ins&gt;fixed-&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;point]] &lt;/ins&gt;numbers&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator in register, denominator and fractional point fixed in ROM.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVI.1&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator and denominator in registers, fractional point fixed in ROM.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVI.1&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator and denominator in registers, fractional point fixed in ROM.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVI.2&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator, denominator and fractional point in registers.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&amp;#160; &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVI.2&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator, denominator and fractional point in registers.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&amp;#160; &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVU&amp;lt;/TD&amp;gt;&amp;lt;TD ROWSPAN=3&amp;gt;Divide two unsigned integers / fixed-&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;pt &lt;/del&gt;numbers&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator in register, denominator and fractional point fixed in ROM.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVU&amp;lt;/TD&amp;gt;&amp;lt;TD ROWSPAN=3&amp;gt;Divide two unsigned integers / fixed-&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;point &lt;/ins&gt;numbers&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator in register, denominator and fractional point fixed in ROM.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVU.1&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator and denominator in registers, fractional point fixed in ROM.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVU.1&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator and denominator in registers, fractional point fixed in ROM.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVU.2&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator, denominator and fractional point in registers.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&amp;lt;/TABLE&amp;gt;&amp;lt;/CENTER&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVU.2&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator, denominator and fractional point in registers.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&amp;lt;/TABLE&amp;gt;&amp;lt;/CENTER&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Mr z</name></author>	</entry>

	<entry>
		<id>http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;diff=2942&amp;oldid=prev</id>
		<title>Mr z: /* Notes */</title>
		<link rel="alternate" type="text/html" href="http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;diff=2942&amp;oldid=prev"/>
				<updated>2008-09-06T20:29:00Z</updated>
		
		<summary type="html">&lt;p&gt;‎&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;Notes&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr style=&quot;vertical-align: top;&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 20:29, 6 September 2008&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l19&quot; &gt;Line 19:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 19:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;= Notes =&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;= Notes =&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;If all of your operands are positive and less than 0x8000, you may consider using [[fastdivu.asm]] instead, since it is noticeably faster.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;If all of your operands are positive and less than 0x8000, you may consider using [[fastdivu.asm]] instead, since it is noticeably faster.&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;&amp;lt;br \&amp;gt;&amp;lt;br \&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;If you are dividing by a power of 2, consider [[Introducing_the_Instruction_Set_Part_4#Using_Shifts_for_Division_by_Powers_of_Two|using shifts instead]].&amp;lt;br \&amp;gt;&amp;lt;br \&amp;gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;= Source Code =&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;= Source Code =&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Mr z</name></author>	</entry>

	<entry>
		<id>http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;diff=2938&amp;oldid=prev</id>
		<title>Mr z: /* Examples */</title>
		<link rel="alternate" type="text/html" href="http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;diff=2938&amp;oldid=prev"/>
				<updated>2008-09-06T20:23:42Z</updated>
		
		<summary type="html">&lt;p&gt;‎&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;Examples&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr style=&quot;vertical-align: top;&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 20:23, 6 September 2008&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l16&quot; &gt;Line 16:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 16:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;(todo... please contribute!)&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;(todo... please contribute!)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;= Notes =&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;If all of your operands are positive and less than 0x8000, you may consider using [[fastdivu.asm]] instead, since it is noticeably faster.&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;= Source Code =&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;= Source Code =&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Mr z</name></author>	</entry>

	<entry>
		<id>http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;diff=2937&amp;oldid=prev</id>
		<title>Mr z at 19:49, 6 September 2008</title>
		<link rel="alternate" type="text/html" href="http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;diff=2937&amp;oldid=prev"/>
				<updated>2008-09-06T19:49:18Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr style=&quot;vertical-align: top;&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 19:49, 6 September 2008&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l1&quot; &gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Programming]] [[Category:Library]]&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:Programming]] [[Category:Library]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;= dividivu.asm =&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;= Functions Provided =&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;=&lt;/del&gt;= Functions Provided &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;=&lt;/del&gt;=&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;CENTER&amp;gt;&amp;lt;TABLE BORDER&amp;gt;&amp;lt;TR&amp;gt;&amp;lt;TH&amp;gt;Entry point&amp;lt;/TH&amp;gt;&amp;lt;TH&amp;gt;Function provided&amp;lt;/TH&amp;gt;&amp;lt;TH&amp;gt;Notes&amp;lt;/TH&amp;gt;&amp;lt;/TR&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;CENTER&amp;gt;&amp;lt;TABLE BORDER&amp;gt;&amp;lt;TR&amp;gt;&amp;lt;TH&amp;gt;Entry point&amp;lt;/TH&amp;gt;&amp;lt;TH&amp;gt;Function provided&amp;lt;/TH&amp;gt;&amp;lt;TH&amp;gt;Notes&amp;lt;/TH&amp;gt;&amp;lt;/TR&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l15&quot; &gt;Line 15:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 13:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;See source code below for calling convention.&amp;lt;br /&amp;gt;&amp;lt;br /&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;See source code below for calling convention.&amp;lt;br /&amp;gt;&amp;lt;br /&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Source Code &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;=&lt;/del&gt;=&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;= &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;Examples =&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;(todo... please contribute!)&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;= Source Code =&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Mr z</name></author>	</entry>

	<entry>
		<id>http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;diff=2936&amp;oldid=prev</id>
		<title>Mr z at 19:37, 6 September 2008</title>
		<link rel="alternate" type="text/html" href="http://wiki.intellivision.us/index.php?title=Dividivu.asm&amp;diff=2936&amp;oldid=prev"/>
				<updated>2008-09-06T19:37:36Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;[[Category:Programming]] [[Category:Library]]&lt;br /&gt;
&lt;br /&gt;
= dividivu.asm =&lt;br /&gt;
&lt;br /&gt;
== Functions Provided ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;CENTER&amp;gt;&amp;lt;TABLE BORDER&amp;gt;&amp;lt;TR&amp;gt;&amp;lt;TH&amp;gt;Entry point&amp;lt;/TH&amp;gt;&amp;lt;TH&amp;gt;Function provided&amp;lt;/TH&amp;gt;&amp;lt;TH&amp;gt;Notes&amp;lt;/TH&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVI&amp;lt;/TD&amp;gt;&amp;lt;TD ROWSPAN=3&amp;gt;Divide two signed integers / fixed-pt numbers&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator in register, denominator and fractional point fixed in ROM.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVI.1&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator and denominator in registers, fractional point fixed in ROM.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVI.2&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator, denominator and fractional point in registers.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;  &lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVU&amp;lt;/TD&amp;gt;&amp;lt;TD ROWSPAN=3&amp;gt;Divide two unsigned integers / fixed-pt numbers&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator in register, denominator and fractional point fixed in ROM.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVU.1&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator and denominator in registers, fractional point fixed in ROM.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&lt;br /&gt;
&amp;lt;TR&amp;gt;&amp;lt;TD&amp;gt;DIVU.2&amp;lt;/TD&amp;gt;&amp;lt;TD&amp;gt;Numerator, denominator and fractional point in registers.&amp;lt;/TD&amp;gt;&amp;lt;/TR&amp;gt;&amp;lt;/TABLE&amp;gt;&amp;lt;/CENTER&amp;gt;&lt;br /&gt;
&amp;lt;br /&amp;gt;&amp;lt;br /&amp;gt;&lt;br /&gt;
See source code below for calling convention.&amp;lt;br /&amp;gt;&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Source Code ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
;* ======================================================================== *;&lt;br /&gt;
;*  These routines are placed into the public domain by their author.  All  *;&lt;br /&gt;
;*  copyright rights are hereby relinquished on the routines and data in    *;&lt;br /&gt;
;*  this file.  -- Joseph Zbiciak, 2008                                     *;&lt;br /&gt;
;* ======================================================================== *;&lt;br /&gt;
&lt;br /&gt;
;; ======================================================================== ;;&lt;br /&gt;
;;  DIVI      Divide two signed integers / fixed-pt numbers                 ;;&lt;br /&gt;
;;  DIVI.1    Alternate entry point:  denominator in register               ;;&lt;br /&gt;
;;  DIVI.2    Alternate entry point:  all parameters in registers           ;;&lt;br /&gt;
;;  DIVU      Divide two unsigned integers / fixed-pt numbers               ;;&lt;br /&gt;
;;  DIVU.1    Alternate entry point:  denominator in register               ;;&lt;br /&gt;
;;  DIVU.2    Alternate entry point:  all parameters in registers           ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;  AUTHOR                                                                  ;;&lt;br /&gt;
;;      Joseph Zbiciak &amp;lt;intvnut AT gmail.com&amp;gt;                               ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;  REVISION HISTORY                                                        ;;&lt;br /&gt;
;;      25-Sep-2001 Initial Revision                                        ;;&lt;br /&gt;
;;      27-Sep-2001 Rewrote normalization, shaving ~150 cycles.             ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;  INPUTS for DIVI, DIVU                                                   ;;&lt;br /&gt;
;;      R0    Numerator                                                     ;;&lt;br /&gt;
;;      R5    Pointer to invocation record, followed by return address.     ;;&lt;br /&gt;
;;            Denominator                  1 DECLE                          ;;&lt;br /&gt;
;;            Fractional point             1 DECLE                          ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;  INPUTS for DIVI.1, DIVU.1                                               ;;&lt;br /&gt;
;;      R0    Numerator                                                     ;;&lt;br /&gt;
;;      R1    Denominator                                                   ;;&lt;br /&gt;
;;      R5    Pointer to invocation record, followed by return address.     ;;&lt;br /&gt;
;;            Fractional point             1 DECLE                          ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;  INPUTS for DIVI.2, DIVU.2                                               ;;&lt;br /&gt;
;;      R0    Numerator                                                     ;;&lt;br /&gt;
;;      R1    Denominator                                                   ;;&lt;br /&gt;
;;      R2    Fraction                                                      ;;&lt;br /&gt;
;;      R5    Return address                                                ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;  OUTPUTS                                                                 ;;&lt;br /&gt;
;;      R0    Remainder, left-shifted                                       ;;&lt;br /&gt;
;;      R1    Clobbered                                                     ;;&lt;br /&gt;
;;      R2    Clobbered                                                     ;;&lt;br /&gt;
;;      R3    Quotient                                                      ;;&lt;br /&gt;
;;      R4    Unmodified                                                    ;;&lt;br /&gt;
;;      R5    Return address                                                ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;  NOTES                                                                   ;;&lt;br /&gt;
;;      The remainder returned in R0 isn't directly usable.  This code      ;;&lt;br /&gt;
;;      can be modified to return a proper remainder by recording the       ;;&lt;br /&gt;
;;      number of left-shifts applied to the denominator in the norm        ;;&lt;br /&gt;
;;      loop, and applying that number of right-shifts to the remainder.    ;;&lt;br /&gt;
;;      Storing R2 after the normalization loop works for integer           ;;&lt;br /&gt;
;;      division (fractional point == 0) only.                              ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;      This code can perform fixed-point divide between two fixed point    ;;&lt;br /&gt;
;;      numbers, yielding a fixed-point result.  Given the numerator's      ;;&lt;br /&gt;
;;      fractional point X, the denominator's fractional point Y, and       ;;&lt;br /&gt;
;;      the desired fractional point Z, the required argument F for         ;;&lt;br /&gt;
;;      this divide is:  F = Z + Y - X.                                     ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;      This divide rounds towards zero.  In other words, for signed        ;;&lt;br /&gt;
;;      division, both -1/2 == 0 and 1/2 == 0.  For unsigned division,      ;;&lt;br /&gt;
;;      all remainders are rounded down.                                    ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;  TECHNIQUES                                                              ;;&lt;br /&gt;
;;      Left-shifting method on numerator allows calculating fractional     ;;&lt;br /&gt;
;;      quotients as well as integer quotients.                             ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;      Negative numerators and denominators are handled by making both     ;;&lt;br /&gt;
;;      numerator and denominator positive up-front, and then negating      ;;&lt;br /&gt;
;;      the result if necessary.  (This step is obviously omitted in the    ;;&lt;br /&gt;
;;      case of an unsigned divide.)                                        ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;  CODESIZE                                                                ;;&lt;br /&gt;
;;      72 words.                                                           ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;      6 words may be shaved by omitting DIVU.                             ;;&lt;br /&gt;
;;      20 words may be shaved by omitting DIVI.                            ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;  CYCLES                                                                  ;;&lt;br /&gt;
;;      Worst case analysis:                                                ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;      For DIVI, cycles = 601 + 53*k, where k is # of quotient bits.       ;;&lt;br /&gt;
;;      For DIVU, cycles = 552 + 53*k, where k is # of quotient bits.       ;;&lt;br /&gt;
;;      The number of quotient bits 'k' is given by this equation:          ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;          k = ceil(log2(num)) - floor(log2(den)) + fractional_bits.       ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;      Subtract  8 cycles for DIVI.1 or DIVU.1.                            ;;&lt;br /&gt;
;;      Subtract 16 cycles for DIVI.2 or DIVU.2.                            ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;;      A worst-case divide with 16 quotient bits that are all 1s should    ;;&lt;br /&gt;
;;      take no more than 1448 cycles.  (The actual cycle count will        ;;&lt;br /&gt;
;;      depend on the relative magnitude of the numbers being divided.)     ;;&lt;br /&gt;
;;                                                                          ;;&lt;br /&gt;
;; ======================================================================== ;;&lt;br /&gt;
DIVU        PROC         &lt;br /&gt;
&lt;br /&gt;
            MVI@    R5,     R1      ;   8   Denominator&lt;br /&gt;
@@1:        MVI@    R5,     R2      ;   8   Fractional point&lt;br /&gt;
@@2:                                ;       Alt. entry: All args in regs&lt;br /&gt;
&lt;br /&gt;
            CLRR    R3              ;   6   Start w/ quotient == 0.&lt;br /&gt;
            PSHR    R3              ;   9   Sign of result == positive&lt;br /&gt;
            B       DIVI.norm       ;   9   Reuse divi code for divide&lt;br /&gt;
                                    ;======&lt;br /&gt;
                                    ;  40  &lt;br /&gt;
            ENDP&lt;br /&gt;
&lt;br /&gt;
DIVI        PROC&lt;br /&gt;
            MVI@    R5,     R1      ;   8   Denominator&lt;br /&gt;
@@1:        MVI@    R5,     R2      ;   8   Fractional point&lt;br /&gt;
@@2:                                ;       Alt. entry: All args in regs&lt;br /&gt;
&lt;br /&gt;
            CLRR    R3              ;   6   Start w/ quotient == 0.&lt;br /&gt;
&lt;br /&gt;
            ;; ------------------------------------------------------------ ;;&lt;br /&gt;
            ;;  Record sign of result, and make num, den positive.          ;;&lt;br /&gt;
            ;; ------------------------------------------------------------ ;;&lt;br /&gt;
            XORR    R1,     R0      ;   6   \&lt;br /&gt;
            PSHR    R0              ;   9    |-- Record sign of result&lt;br /&gt;
            XORR    R1,     R0      ;   6   /    on the stack.&lt;br /&gt;
&lt;br /&gt;
            TSTR    R0              ;   6   \&lt;br /&gt;
            BEQ     @@zero          ;   7/9  |__ Make numerator positive&lt;br /&gt;
            BPL     @@npos          ;   7/9  |&lt;br /&gt;
            NEGR    R0              ;   6   /&lt;br /&gt;
@@npos:&lt;br /&gt;
            TSTR    R1              ;   6   \&lt;br /&gt;
            BEQ     @@zero          ;   7/9  |__ Make denominator positive&lt;br /&gt;
            BPL     @@dpos          ;   7/9  |&lt;br /&gt;
            NEGR    R1              ;   6   /&lt;br /&gt;
@@dpos:                             ;------&lt;br /&gt;
                                    ;  95  (worst case: both negative)&lt;br /&gt;
                                    ;  87  (typical:    both positive)&lt;br /&gt;
                                    ;  58  (best case:  numerator zero)&lt;br /&gt;
                                    ;======&lt;br /&gt;
                                    ;  95  (worst case: both negative)&lt;br /&gt;
&lt;br /&gt;
            ;; ------------------------------------------------------------ ;;&lt;br /&gt;
            ;;  Normalize the divisor relative to the dividend.  We want    ;;&lt;br /&gt;
            ;;  to shift the denominator left as far as we can without      ;;&lt;br /&gt;
            ;;  making it larger than the numerator.  We achieve this by    ;;&lt;br /&gt;
            ;;  shifting it one position too far, then backing off.         ;;&lt;br /&gt;
            ;; ------------------------------------------------------------ ;;&lt;br /&gt;
@@norm:     TSTR    R1              ;   6   Is bit 15 of denominator set?&lt;br /&gt;
            BMI     @@norm3         ;   7/9 Yes:  Do very special norm.&lt;br /&gt;
            TSTR    R0              ;   6   Is bit 15 of numerator set?&lt;br /&gt;
            BPL     @@norm1         ;   9/7 If not, do general normalize.&lt;br /&gt;
                                    ;       Otherwise, do special normalize.&lt;br /&gt;
&lt;br /&gt;
@@norm2:    INCR    R2              ;   6   \&lt;br /&gt;
            SLLC    R1,     1       ;   6    |-- Special normalize:  Shift&lt;br /&gt;
            BNC     @@norm2         ;   9/7 /    until bit falls off top.&lt;br /&gt;
                                    ;------&lt;br /&gt;
                                    ;  21*k - 2&lt;br /&gt;
            B       @@over          ;   9&lt;br /&gt;
                                    ;  26&lt;br /&gt;
                                    ;------&lt;br /&gt;
                                    ;  21*k + 20&lt;br /&gt;
                                    ;======      Assume max K of 16&lt;br /&gt;
                                    ; 369        (worst case)&lt;br /&gt;
&lt;br /&gt;
@@norm1:    INCR    R2              ;   6   \&lt;br /&gt;
            SLL     R1,     1       ;   6    |-- General normalize:  Shift&lt;br /&gt;
            CMPR    R1,     R0      ;   6   /    until denom &amp;gt; numer.&lt;br /&gt;
            BC      @@norm1         ;   9/7&lt;br /&gt;
                                    ;------&lt;br /&gt;
                                    ;  27*k - 2&lt;br /&gt;
                                    ;  28&lt;br /&gt;
                                    ;======      Assume max K of 15&lt;br /&gt;
                                    ; 431        (worst case)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
@@over:     RRC     R1,     1       ;   6   Back off by one. &lt;br /&gt;
            INCR    PC              ;   6   Skip INCR below&lt;br /&gt;
@@norm3:    INCR    R2              ;   6   Very special norm...&lt;br /&gt;
            CMPR    R3,     R2      ;   6   Is our divide loop iter count&lt;br /&gt;
                                    ;       at least 1?   (Note R3==0)&lt;br /&gt;
            BLE     @@zero          ;   7/9 NO:  Return zero.&lt;br /&gt;
            B       @@div1st        ;   9   Do first iter of divide&lt;br /&gt;
                                    ;------&lt;br /&gt;
                                    ;  34        (worst case)&lt;br /&gt;
                                    ;  95        (worst case)&lt;br /&gt;
                                    ; 431        (worst case)&lt;br /&gt;
                                    ;======      &lt;br /&gt;
                                    ; 560        (worst case)&lt;br /&gt;
&lt;br /&gt;
            ;; ------------------------------------------------------------ ;;&lt;br /&gt;
            ;;  Perform the divide.  We iteratively subtract off our        ;;&lt;br /&gt;
            ;;  divisor from the dividend *IF* the dividend is greater or   ;;&lt;br /&gt;
            ;;  or equal to the divisor, and set the corresponding bit in   ;;&lt;br /&gt;
            ;;  the quotient.  If the dividend is smaller than the divisor, ;;&lt;br /&gt;
            ;;  we clear the corresponding quotient bit.  Next, we left-    ;;&lt;br /&gt;
            ;;  shift the dividend and calculate the next quotient bit.     ;;&lt;br /&gt;
            ;; ------------------------------------------------------------ ;;&lt;br /&gt;
&lt;br /&gt;
@@div:      SLLC    R0,     1       ;   6   Shift numerator left 1&lt;br /&gt;
            BC      @@b1            ;   7/9 If overflow, force bit 1.&lt;br /&gt;
@@div1st:   CMPR    R1,     R0      ;   6   Is numerator &amp;gt;= denominator ?&lt;br /&gt;
            BNC     @@b0            ;   7/9 NO:   Quotient bit is 0&lt;br /&gt;
&lt;br /&gt;
@@b1:       RLC     R3,     1       ;   6   YES:  Quotient bit is 1&lt;br /&gt;
            SUBR    R1,     R0      ;   6&lt;br /&gt;
            DECR    R2              ;   6&lt;br /&gt;
            BNEQ    @@div           ;   9/7 Iterate for all quotient bits&lt;br /&gt;
                                    ;------&lt;br /&gt;
                                    ;  53*k - 2&lt;br /&gt;
            B       @@divdone       ;   9&lt;br /&gt;
                                    ;------&lt;br /&gt;
                                    ;  53*k + 7&lt;br /&gt;
&lt;br /&gt;
@@b0:       SLL     R3,     1       ;   6   NO:   Quotient bit is 0&lt;br /&gt;
            DECR    R2              ;   6&lt;br /&gt;
            BNEQ    @@div           ;   9/7 Iterate for all quotient bits&lt;br /&gt;
                                    ;------&lt;br /&gt;
                                    ;  49*k - 2&lt;br /&gt;
                                    &lt;br /&gt;
                                    ;======&lt;br /&gt;
                                    ; 567 + 53*k worst case.&lt;br /&gt;
@@divdone:            &lt;br /&gt;
            ;; ------------------------------------------------------------ ;;&lt;br /&gt;
            ;;  Now apply the sign to the result.  The sign is in the MSB   ;;&lt;br /&gt;
            ;;  of the word we saved earlier on the stack.  For unsigned    ;;&lt;br /&gt;
            ;;  divides, the value saved on the stack is zero.              ;;&lt;br /&gt;
            ;; ------------------------------------------------------------ ;;&lt;br /&gt;
@@zero:     PULR    R1              ;   8&lt;br /&gt;
            TSTR    R1              ;   6&lt;br /&gt;
            BPL     @@qpos          ;   7/9&lt;br /&gt;
            NEGR    R3              ;   6&lt;br /&gt;
@@qpos:                             ;------&lt;br /&gt;
                                    ;  27         (worst case)&lt;br /&gt;
                                    ; 567 + 53*k  (worst case)&lt;br /&gt;
                                    ;======&lt;br /&gt;
                                    ; 594 + 53*k  (worst case)&lt;br /&gt;
&lt;br /&gt;
@@done:     JR      R5              ;   7   Return.  R3 = R0 / R1&lt;br /&gt;
                                    ;======&lt;br /&gt;
                                    ; 601 + 53*k  (worst case)&lt;br /&gt;
            ENDP    &lt;br /&gt;
&lt;br /&gt;
;; ======================================================================== ;;&lt;br /&gt;
;;  End of File:  dividivu.asm                                              ;;&lt;br /&gt;
;; ======================================================================== ;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Mr z</name></author>	</entry>

	</feed>