What is routine? - Definition from WhatIs.com
Part of the Programming glossary:

In computer programming, routine and subroutine are general and nearly synonymous terms for any sequence of code that is intended to be called and used repeatedly during the executable of a program. This makes the program shorter and easier to write (and also to read when necessary). The main sequence of logic in a program can branch off to a common routine when necessary. When finished, the routine branches back to the next sequential instruction following the instruction that branched to it. A routine may also be useful in more than one program and save other programmers from having to write code than can be shared.

Typically, in assembler languages, a routine that requires some variable input can be encoded into a macro definition with a specified interface called a macro instruction . The programmer can then use a macro instruction instead of having to include and manage the branching to a routine. Macro definitions and instructions also tend to be shared among programmers for use in multiple programs, especially in software development projects.

In higher-level computer languages, many commonly-needed routines are prepackaged as function , which are routines with specified programming interfaces. Some functions can be compiled in line with other code. Other functions are compiled in as stub that make dynamic calls for system services during program execution. Functions are sometimes called library routines . The compiler and a set of library routines usually come as part of a related software development package.

In Windows and some other personal computer operating systems, the system routines for handling specific tasks such as interacting with specific I/O devices are called dynamic link library ( dynamic link library ) routines. These routines are dynamic because their files are not actually loaded into memory until the first time they are called.

A more recent term, procedure , is similar in meaning.

This was last updated in April 2005
Contributor(s): Selena Ozuna
Posted by: Margaret Rouse

Related Terms

Definitions

  • headless Android

    - Headless Android is a version of the Android operating system designed for embedded devices that lack user interfaces. (WhatIs.com)

  • embedded software

    - Hardware makers use embedded software to control the functions of various hardware devices and systems. Embedded software controls device functions in the same way that a computer’s operating syste... (WhatIs.com)

  • framework

    - In computer systems, a framework is often a layered structure indicating what kind of programs can or should be built and how they would interrelate. (WhatIs.com)

Glossaries

  • Programming

    - Terms related to software programming, including definitions about programming languages and words and phrases about software design, coding, testing and debugging.

  • Internet applications

    - This WhatIs.com glossary contains terms related to Internet applications, including definitions about Software as a Service (SaaS) delivery models and words and phrases about web sites, e-commerce ...

Ask a Question. Find an Answer.Powered by ITKnowledgeExchange.com

Ask An IT Question

Get answers from your peers on your most technical challenges

Ask Question
  • Can't connect due to our broadband line

  • RPG Move command

    INZ initializes a variable, it intelligently move values according to data types. Secondly I have seen Z-ADD or ADD to move numeric values in numeric variables rather then just MOVE. MOVE is more s...

  • How to debug piece of code added as CPYSRC

    I will sometimes compile the program to QTEMP to debug. Then you will get an expanded source QRPGLESRC in QTEMP with the copy source included. Then just debug this and you should be fine.Forgot to ...

Tech TalkComment

Share
Comments

    Results

    Contribute to the conversation

    All fields are required. Comments will appear at the bottom of the article.