Commit Graph

35 Commits (522593f901baff3f1ba334ecaad9eefd6a9c9316)

Author SHA1 Message Date
Kinsey Moore 9b16c8b0f6 Clean up and ensure proper usage of alloca()
13 years ago
Kevin P. Fleming 166b4e2b30 Multiple revisions 369001-369002
13 years ago
Richard Mudgett dd2427c141 Coverity Report: Fix issues for error type REVERSE_INULL (core modules)
13 years ago
Kinsey Moore dd81b047db Resolve FORWARD_NULL static analysis warnings
13 years ago
Tilghman Lesher 9af5c769c3 Enable macros in 1.8 to find the next highest "h" extension in a context, like in 1.4.
13 years ago
Tilghman Lesher 8cca4ed8d8 Merged revisions 299449 via svnmerge from
15 years ago
Tilghman Lesher bddb242d72 Merged revisions 290255 via svnmerge from
15 years ago
Jeff Peeler b3281ac725 Merged revisions 271552 via svnmerge from
15 years ago
Jeff Peeler 54f2dfc91c Merged revisions 271399 via svnmerge from
15 years ago
Leif Madsen c17cda109a Revert previous WARNING message removal.
15 years ago
Leif Madsen 881450ec82 Remove unnecessary WARNING message in ael/pval.c
15 years ago
Tilghman Lesher 78012e4f71 When we call a gosub routine, the variables should be scoped to avoid contaminating the caller.
16 years ago
Tilghman Lesher 642bec4d6f AST-2009-005
16 years ago
Steve Murphy bdfda9ea23 Merged revisions 168745 via svnmerge from
17 years ago
Steve Murphy 67cb0526b7 Merged revisions 162013 via svnmerge from
17 years ago
Sean Bright 574f2daa2a Fix one case where the application argument was not converted from a pipe to
17 years ago
Steve Murphy 068859119a In these changes, I have added some explanation
17 years ago
Steve Murphy a40f1cc1c5 Merged revisions 136726 via svnmerge from
17 years ago
Steve Murphy 37001f58ff Merged revisions 131242 via svnmerge from
17 years ago
Steve Murphy 7372474c94 Merged revisions 119929 via svnmerge from
17 years ago
Steve Murphy 2427603eaf Merged revisions 111341 via svnmerge from
17 years ago
Steve Murphy 377e51c4d4 (closes issue #6002)
17 years ago
Luigi Rizzo 51391e6b09 shuffle a little bit the content of header files to reduce dependencies.
18 years ago
Steve Murphy a897556f7f This is the perhaps the biggest, boldest, most daring change I've ever committed to trunk. Forgive me in advance any disruption this may cause, and please, report any problems via the bugtracker. The upside is that this can speed up large dialplans by 20 times (or more). Context, extension, and priority matching are all fairly constant-time searches. I introduce here my hashtables (hashtabs), and a regression for them. I would have used the ast_obj2 tables, but mine are resizeable, and don't need the object destruction capability. The hashtab stuff is well tested and stable. I introduce a data structure, a trie, for extension pattern matching, in which knowledge of all patterns is accumulated, and all matches can be found via a single traversal of the tree. This is per-context. The trie is formed on the first lookup attempt, and stored in the context for future lookups. Destruction routines are in place for hashtabs and the pattern match trie. You can see the contents of the pattern match trie by using the 'dialplan show' cli command when 'core set debug' has been done to put it in debug mode. The pattern tree traversal only traverses those parts of the tree that are interesting. It uses a scoreboard sort of approach to find the best match. The speed of the traversal is more a function of the length of the pattern than the number of patterns in the tree. The tree also contains the CID matching patterns. See the source code comments for details on how everything works. I believe the approach general enough that any issues that might come up involving fine points in the pattern matching algorithm, can be solved by just tweaking things. We shall see. The current pattern matcher is fairly involved, and replicating every nuance of it is difficult. If you find and report problems, I will try to resolve than as quickly as I can. The trie and hashtabs are added to the existing context and exten structs, and none of the old machinery has been removed for the sake of the multitude of functions that use them. In the future, we can (maybe) weed out the linked lists and save some space.
18 years ago
Steve Murphy 63f2f04cf4 This commits the performance mods that give the priority processing engine in the pbx, a 25-30% speed boost. The two updates used, are, first, to merge the ast_exists_extension() and the ast_spawn_extension() where they are called sequentially in a loop in the code, into a slightly upgraded version of ast_spawn_extension(), with a few extra args; and, second, I modified the substitute_variables_helper_full, so it zeroes out the byte after the evaluated string instead of demanding you pre-zero the buffer; I also went thru the code and removed the code that zeroed this buffer before every call to the substitute_variables_helper_full. The first fix provides about a 9% speedup, and the second the rest. These figures come from the 'PIPS' benchmark I describe in blogs, conf. reports, etc.
18 years ago
Steve Murphy 8c5bf67f4a Merged revisions 87775 via svnmerge from
18 years ago
Steve Murphy c9f3efc381 Merged revisions 87168 via svnmerge from
18 years ago
Steve Murphy 3ffa04bbd3 Merged revisions 84511 via svnmerge from
18 years ago
Steve Murphy b3168a76c9 Merged revisions 84239 via svnmerge from
18 years ago
Joshua Colp 20a71bad79 Fix minor memory leak in pval.c. Overwriting a value without freeing the previous result is bad, mmmk?
18 years ago
Steve Murphy 4f013699e2 Merged revisions 83589 via svnmerge from
18 years ago
Steve Murphy f2b38cf2f3 Merged revisions 83558 via svnmerge from
18 years ago
Russell Bryant 9388173f85 Make the MALLOC_DEBUG output for free() useful again. After changing calls to
18 years ago
Steve Murphy 35ade91df6 As per 10472, mvanbaak thought the generated code would look better this way.
18 years ago
Steve Murphy 9836efb5fb This commit closes bug 7605, and half-closes 7638. The AEL code has been redistributed/repartitioned to allow code re-use both inside and outside of Asterisk. This commit introduces the utils/conf2ael program, and an external config-file reader, for both normal config files, and for extensions.conf (context, exten, prio); It provides an API for programs outside of asterisk to use to play with the dialplan and config files.
18 years ago